diff options
author | Ulf Hansson <ulf.hansson@linaro.org> | 2014-12-05 11:31:22 +0100 |
---|---|---|
committer | Ulf Hansson <ulf.hansson@linaro.org> | 2014-12-08 09:11:04 +0100 |
commit | fe5afb13d46e76b07ab7e732f2b694dcafef4d9d (patch) | |
tree | d424d9f91774042e9c7e57883052b61bf3d99e29 /drivers/mmc | |
parent | fdb409f636cd6fc3ac4e2f9c880402860e738554 (diff) | |
download | linux-fe5afb13d46e76b07ab7e732f2b694dcafef4d9d.tar.gz linux-fe5afb13d46e76b07ab7e732f2b694dcafef4d9d.tar.bz2 linux-fe5afb13d46e76b07ab7e732f2b694dcafef4d9d.zip |
mmc: core: Let mmc_send_tuning() to take struct mmc_host* as parameter
To be able to use mmc_send_tuning() prior the struct mmc_card has been
allocated, let's convert it to take the struct mmc_host* as parameter
instead.
Suggested-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Acked-by: Dong Aisheng <b29396@freescale.com>
Reviewed-by: Stephen Boyd <sboyd@codeaurora.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/core/mmc_ops.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/mmc/core/mmc_ops.c b/drivers/mmc/core/mmc_ops.c index 12b2a32df346..3b044c5b029c 100644 --- a/drivers/mmc/core/mmc_ops.c +++ b/drivers/mmc/core/mmc_ops.c @@ -547,14 +547,13 @@ int mmc_switch(struct mmc_card *card, u8 set, u8 index, u8 value, } EXPORT_SYMBOL_GPL(mmc_switch); -int mmc_send_tuning(struct mmc_card *card) +int mmc_send_tuning(struct mmc_host *host) { struct mmc_request mrq = {NULL}; struct mmc_command cmd = {0}; struct mmc_data data = {0}; struct scatterlist sg; - struct mmc_host *mmc = card->host; - struct mmc_ios *ios = &mmc->ios; + struct mmc_ios *ios = &host->ios; const u8 *tuning_block_pattern; int size, err = 0; u8 *data_buf; @@ -596,7 +595,7 @@ int mmc_send_tuning(struct mmc_card *card) data.sg_len = 1; sg_init_one(&sg, data_buf, size); - mmc_wait_for_req(mmc, &mrq); + mmc_wait_for_req(host, &mrq); if (cmd.error) { err = cmd.error; |