[PATCH 05/60] mtd: devices: m25p80: show device in sysfs

From: Frans Klaver
Date: Tue Mar 03 2015 - 16:58:22 EST


Fix a bug where mtd devices aren't shown in sysfs.

Signed-off-by: Frans Klaver <fransklaver@xxxxxxxxx>
---
drivers/mtd/devices/m25p80.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
index 85e35467..48eee8f 100644
--- a/drivers/mtd/devices/m25p80.c
+++ b/drivers/mtd/devices/m25p80.c
@@ -206,6 +206,7 @@ static int m25p_probe(struct spi_device *spi)

spi_set_drvdata(spi, flash);
flash->mtd.priv = nor;
+ flash->mtd.dev.parent = &spi->dev;
flash->spi = spi;

if (spi->mode & SPI_RX_QUAD)
--
2.2.2

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/