staging: mt29f_spinand: show parent device in sysfs
Linux-MTD Mailing List
linux-mtd at lists.infradead.org
Fri Nov 6 10:59:20 PST 2015
Gitweb: http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=efefcaee7610c0762c34123d121ef77f6e550214
Commit: efefcaee7610c0762c34123d121ef77f6e550214
Parent: fd511e218c6a3272ce6a57be9c41e1bc09e37306
Author: Frans Klaver <fransklaver at gmail.com>
AuthorDate: Wed Jun 10 22:39:14 2015 +0200
Committer: Brian Norris <computersforpeace at gmail.com>
CommitDate: Tue Oct 13 12:56:44 2015 -0700
staging: mt29f_spinand: show parent device in sysfs
Fix a bug where mtd parent device symlinks aren't shown in sysfs.
While at it, take advantage of the default owner and name values set by
mtdcore.
Signed-off-by: Frans Klaver <fransklaver at gmail.com>
Acked-by: Greg Kroah-Hartman <gregkh at linuxfoundation.org>
Signed-off-by: Brian Norris <computersforpeace at gmail.com>
---
drivers/staging/mt29f_spinand/mt29f_spinand.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/staging/mt29f_spinand/mt29f_spinand.c b/drivers/staging/mt29f_spinand/mt29f_spinand.c
index ad30ce4..9a8ddbb 100644
--- a/drivers/staging/mt29f_spinand/mt29f_spinand.c
+++ b/drivers/staging/mt29f_spinand/mt29f_spinand.c
@@ -912,8 +912,7 @@ static int spinand_probe(struct spi_device *spi_nand)
dev_set_drvdata(&spi_nand->dev, mtd);
mtd->priv = chip;
- mtd->name = dev_name(&spi_nand->dev);
- mtd->owner = THIS_MODULE;
+ mtd->dev.parent = &spi_nand->dev;
mtd->oobsize = 64;
if (nand_scan(mtd, 1))
More information about the linux-mtd-cvs
mailing list