summaryrefslogtreecommitdiffstats
path: root/drivers/mmc/mmc.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2016-02-29 15:25:51 -0700
committerSimon Glass <sjg@chromium.org>2016-03-14 15:34:50 -0600
commitbcce53d048de7f41078d25e39aa2f26d752d3658 (patch)
tree5eb88ab671c7ec923cfb4fe9c0d3dc4715adb93d /drivers/mmc/mmc.c
parent782b97805e9f59cc2b4d3aa67a8a03248e8cd722 (diff)
downloadtalos-obmc-uboot-bcce53d048de7f41078d25e39aa2f26d752d3658.tar.gz
talos-obmc-uboot-bcce53d048de7f41078d25e39aa2f26d752d3658.zip
dm: block: Rename device number member dev to devnum
This is a device number, and we want to use 'dev' to mean a driver model device. Rename the member. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Stephen Warren <swarren@nvidia.com>
Diffstat (limited to 'drivers/mmc/mmc.c')
-rw-r--r--drivers/mmc/mmc.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index 94afbb105e..8b2e6069ea 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -182,7 +182,7 @@ struct mmc *find_mmc_device(int dev_num)
list_for_each(entry, &mmc_devices) {
m = list_entry(entry, struct mmc, link);
- if (m->block_dev.dev == dev_num)
+ if (m->block_dev.devnum == dev_num)
return m;
}
@@ -237,7 +237,7 @@ static int mmc_read_blocks(struct mmc *mmc, void *dst, lbaint_t start,
static ulong mmc_bread(struct blk_desc *block_dev, lbaint_t start,
lbaint_t blkcnt, void *dst)
{
- int dev_num = block_dev->dev;
+ int dev_num = block_dev->devnum;
int err;
lbaint_t cur, blocks_todo = blkcnt;
@@ -1556,7 +1556,7 @@ struct mmc *mmc_create(const struct mmc_config *cfg, void *priv)
mmc->dsr = 0xffffffff;
/* Setup the universal parts of the block interface just once */
mmc->block_dev.if_type = IF_TYPE_MMC;
- mmc->block_dev.dev = cur_dev_num++;
+ mmc->block_dev.devnum = cur_dev_num++;
mmc->block_dev.removable = 1;
mmc->block_dev.block_read = mmc_bread;
mmc->block_dev.block_write = mmc_bwrite;
@@ -1728,7 +1728,7 @@ void print_mmc_devices(char separator)
else
mmc_type = NULL;
- printf("%s: %d", m->cfg->name, m->block_dev.dev);
+ printf("%s: %d", m->cfg->name, m->block_dev.devnum);
if (mmc_type)
printf(" (%s)", mmc_type);
OpenPOWER on IntegriCloud