summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/mtdoob.c
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2016-02-08 14:25:05 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2016-02-09 09:34:11 +0100
commitd51d58929e450fd922bf486fa6b14ca8708b05f4 (patch)
tree6ad2a07e7c039003e9e05066be91ceacd5262146 /drivers/mtd/mtdoob.c
parent81737c1d436add87e26a22dca9dd750b9655de01 (diff)
downloadbarebox-d51d58929e450fd922bf486fa6b14ca8708b05f4.tar.gz
barebox-d51d58929e450fd922bf486fa6b14ca8708b05f4.tar.xz
mtd: mtdoob device: change name to have the chip name first
Normally all device files assoctiated to a mtd device begin with the chip name itself. Only the mtdoob device is an exception: it begins with the chip name without the index end ends with the index. Change the name to be like the other names, i.e. change nand_oob0 to nand0.oob. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/mtd/mtdoob.c')
-rw-r--r--drivers/mtd/mtdoob.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/mtdoob.c b/drivers/mtd/mtdoob.c
index 6160ddba08..4dcf2f5915 100644
--- a/drivers/mtd/mtdoob.c
+++ b/drivers/mtd/mtdoob.c
@@ -79,7 +79,7 @@ static int add_mtdoob_device(struct mtd_info *mtd, const char *devname, void **p
mtdoob = xzalloc(sizeof(*mtdoob));
mtdoob->cdev.ops = &mtd_ops_oob;
mtdoob->cdev.size = mtd_div_by_wb(mtd->size, mtd) * mtd->oobsize;
- mtdoob->cdev.name = asprintf("%s_oob%d", devname, mtd->class_dev.id);
+ mtdoob->cdev.name = asprintf("%s.oob", mtd->cdev.name);
mtdoob->cdev.priv = mtdoob;
mtdoob->cdev.dev = &mtd->class_dev;
mtdoob->mtd = mtd;