mtd: nand: atmel_nand: show parent device in sysfs

Linux-MTD Mailing List linux-mtd at lists.infradead.org
Fri Nov 6 10:59:15 PST 2015


Gitweb:     http://git.infradead.org/?p=mtd-2.6.git;a=commit;h=03c287d21f52e0cb368d6577bd75db3cc9e42b0b
Commit:     03c287d21f52e0cb368d6577bd75db3cc9e42b0b
Parent:     72169755cf36ce28bed83d6742d28ce4157f7538
Author:     Frans Klaver <fransklaver at gmail.com>
AuthorDate: Wed Jun 10 22:38:36 2015 +0200
Committer:  Brian Norris <computersforpeace at gmail.com>
CommitDate: Tue Oct 13 12:56:25 2015 -0700

    mtd: nand: atmel_nand: show parent device in sysfs
    
    Fix a bug where parent device symlinks aren't shown in sysfs.
    
    While at it, make use of the default owner value set by mtdcore.
    
    Signed-off-by: Frans Klaver <fransklaver at gmail.com>
    Signed-off-by: Brian Norris <computersforpeace at gmail.com>
---
 drivers/mtd/nand/atmel_nand.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mtd/nand/atmel_nand.c b/drivers/mtd/nand/atmel_nand.c
index 46010bd..8989473 100644
--- a/drivers/mtd/nand/atmel_nand.c
+++ b/drivers/mtd/nand/atmel_nand.c
@@ -2126,7 +2126,7 @@ static int atmel_nand_probe(struct platform_device *pdev)
 
 	nand_chip->priv = host;		/* link the private data structures */
 	mtd->priv = nand_chip;
-	mtd->owner = THIS_MODULE;
+	mtd->dev.parent = &pdev->dev;
 
 	/* Set address of NAND IO lines */
 	nand_chip->IO_ADDR_R = host->io_base;



More information about the linux-mtd-cvs mailing list