mtd: nand: nuc900_nand: show parent device in sysfs
authorFrans Klaver <fransklaver@gmail.com>
Wed, 10 Jun 2015 20:38:56 +0000 (22:38 +0200)
committerBrian Norris <computersforpeace@gmail.com>
Tue, 13 Oct 2015 19:56:33 +0000 (12:56 -0700)
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@gmail.com>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
drivers/mtd/nand/nuc900_nand.c

index e58c644dd2205ec15985ee7c5de6217165052163..f0687f71fbd895eb90d8b7d880180450373197e2 100644 (file)
@@ -250,7 +250,7 @@ static int nuc900_nand_probe(struct platform_device *pdev)
        chip = &(nuc900_nand->chip);
 
        nuc900_nand->mtd.priv   = chip;
-       nuc900_nand->mtd.owner  = THIS_MODULE;
+       nuc900_nand->mtd.dev.parent = &pdev->dev;
        spin_lock_init(&nuc900_nand->lock);
 
        nuc900_nand->clk = devm_clk_get(&pdev->dev, NULL);