| From | Alexander Holler <> | Subject | [PATCH 26/27] mtd: nand: txx9ndfmc: show device structure in sysfs | Date | Tue, 27 May 2014 00:12:51 +0200 |
| |
Fix a common error in nand-drivers which do not set up a parent device for the mtd-device by using a new inline function.
Signed-off-by: Alexander Holler <holler@ahsoftware.de> --- drivers/mtd/nand/txx9ndfmc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/mtd/nand/txx9ndfmc.c b/drivers/mtd/nand/txx9ndfmc.c index c1622a5..88b8d34 100644 --- a/drivers/mtd/nand/txx9ndfmc.c +++ b/drivers/mtd/nand/txx9ndfmc.c @@ -323,9 +323,7 @@ static int __init txx9ndfmc_probe(struct platform_device *dev) continue; chip = &txx9_priv->chip; mtd = &txx9_priv->mtd; - mtd->owner = THIS_MODULE; - - mtd->priv = chip; + mtd_setup_common_members(mtd, chip, dev); chip->read_byte = txx9ndfmc_read_byte; chip->read_buf = txx9ndfmc_read_buf; -- 1.8.3.2
|