aboutsummaryrefslogtreecommitdiff
path: root/drivers/mmc/mmc_write.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2016-05-01 13:52:35 -0600
committerSimon Glass <sjg@chromium.org>2016-05-17 09:54:43 -0600
commitc40fdca6b7db469d3982cc44fd68a269adb41b25 (patch)
treea95063f9ae5b62a66999fcfb00a90dbf8edd226a /drivers/mmc/mmc_write.c
parentcffe5d86cfe853ae9271d37522f8bc5795cc4c69 (diff)
downloadu-boot-c40fdca6b7db469d3982cc44fd68a269adb41b25.zip
u-boot-c40fdca6b7db469d3982cc44fd68a269adb41b25.tar.gz
u-boot-c40fdca6b7db469d3982cc44fd68a269adb41b25.tar.bz2
dm: mmc: Move the device list into a separate file
At present the MMC subsystem maintains its own list of MMC devices. This cannot work with driver model, which needs to maintain this itself. Move the list code into a separate 'legacy' file. The core MMC code remains, and will be shared with the driver-model implementation. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/mmc/mmc_write.c')
-rw-r--r--drivers/mmc/mmc_write.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/mmc_write.c b/drivers/mmc/mmc_write.c
index f4d42aa..bd07b20 100644
--- a/drivers/mmc/mmc_write.c
+++ b/drivers/mmc/mmc_write.c
@@ -122,9 +122,9 @@ static ulong mmc_write_blocks(struct mmc *mmc, lbaint_t start,
struct mmc_data data;
int timeout = 1000;
- if ((start + blkcnt) > mmc->block_dev.lba) {
+ if ((start + blkcnt) > mmc_get_blk_desc(mmc)->lba) {
printf("MMC: block number 0x" LBAF " exceeds max(0x" LBAF ")\n",
- start + blkcnt, mmc->block_dev.lba);
+ start + blkcnt, mmc_get_blk_desc(mmc)->lba);
return 0;
}