summaryrefslogtreecommitdiff
path: root/drivers/mtd
diff options
context:
space:
mode:
authorMarek Vasut <marek.vasut@gmail.com>2010-07-28 09:36:54 +0400
committerDavid Woodhouse <David.Woodhouse@intel.com>2010-08-06 12:21:56 +0400
commit81cbb0b17796d81cbd92defe113cf2a7c7a21fbb (patch)
treeb5d32e38ecebf14b8561603beca3c4f69d5a2ab1 /drivers/mtd
parent6f92355c6e7a680c8f61f3ae30e870d05843b98f (diff)
downloadlinux-81cbb0b17796d81cbd92defe113cf2a7c7a21fbb.tar.xz
mtd: gen_nand: fix support for multiple chips
This patch corrects a problem where gen_nand driver assumed there can be only one chip and ignored the pdata->chip.nr_chips value. Signed-off-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/nand/plat_nand.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/nand/plat_nand.c b/drivers/mtd/nand/plat_nand.c
index 8d467315f02b..90e143e5ad3e 100644
--- a/drivers/mtd/nand/plat_nand.c
+++ b/drivers/mtd/nand/plat_nand.c
@@ -91,7 +91,7 @@ static int __devinit plat_nand_probe(struct platform_device *pdev)
}
/* Scan to find existance of the device */
- if (nand_scan(&data->mtd, 1)) {
+ if (nand_scan(&data->mtd, pdata->chip.nr_chips)) {
err = -ENXIO;
goto out;
}