aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd
diff options
context:
space:
mode:
authorDavid Woodhouse <dwmw2@infradead.org>2007-01-17 18:34:51 -0500
committerDavid Woodhouse <dwmw2@infradead.org>2007-01-17 18:34:51 -0500
commit9cdf083f981b8d37b3212400a359368661385099 (patch)
treeaa15a6a08ad87e650dea40fb59b3180bef0d345b /drivers/mtd
parente499e01d234a31d59679b7b1e1cf628d917ba49a (diff)
parenta8b3485287731978899ced11f24628c927890e78 (diff)
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/devices/m25p80.c6
-rw-r--r--drivers/mtd/devices/mtd_dataflash.c4
-rw-r--r--drivers/mtd/maps/Kconfig2
-rw-r--r--drivers/mtd/maps/cfi_flagadm.c2
-rw-r--r--drivers/mtd/rfd_ftl.c2
5 files changed, 8 insertions, 8 deletions
diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
index ef4a731ca5c2..78c2511ae9e0 100644
--- a/drivers/mtd/devices/m25p80.c
+++ b/drivers/mtd/devices/m25p80.c
@@ -437,7 +437,7 @@ static int __devinit m25p_probe(struct spi_device *spi)
437 * or JEDEC get-id commands. Try them ... 437 * or JEDEC get-id commands. Try them ...
438 */ 438 */
439 DEBUG(MTD_DEBUG_LEVEL1, "%s: no chip id\n", 439 DEBUG(MTD_DEBUG_LEVEL1, "%s: no chip id\n",
440 flash->spi->dev.bus_id); 440 spi->dev.bus_id);
441 return -ENODEV; 441 return -ENODEV;
442 } 442 }
443 443
@@ -447,11 +447,11 @@ static int __devinit m25p_probe(struct spi_device *spi)
447 } 447 }
448 if (i == ARRAY_SIZE(m25p_data)) { 448 if (i == ARRAY_SIZE(m25p_data)) {
449 DEBUG(MTD_DEBUG_LEVEL1, "%s: unrecognized id %s\n", 449 DEBUG(MTD_DEBUG_LEVEL1, "%s: unrecognized id %s\n",
450 flash->spi->dev.bus_id, data->type); 450 spi->dev.bus_id, data->type);
451 return -ENODEV; 451 return -ENODEV;
452 } 452 }
453 453
454 flash = kzalloc(sizeof *flash, SLAB_KERNEL); 454 flash = kzalloc(sizeof *flash, GFP_KERNEL);
455 if (!flash) 455 if (!flash)
456 return -ENOMEM; 456 return -ENOMEM;
457 457
diff --git a/drivers/mtd/devices/mtd_dataflash.c b/drivers/mtd/devices/mtd_dataflash.c
index 10a4f4e263fe..a987e917f4e0 100644
--- a/drivers/mtd/devices/mtd_dataflash.c
+++ b/drivers/mtd/devices/mtd_dataflash.c
@@ -459,7 +459,7 @@ add_dataflash(struct spi_device *spi, char *name,
459 struct mtd_info *device; 459 struct mtd_info *device;
460 struct flash_platform_data *pdata = spi->dev.platform_data; 460 struct flash_platform_data *pdata = spi->dev.platform_data;
461 461
462 priv = (struct dataflash *) kzalloc(sizeof *priv, GFP_KERNEL); 462 priv = kzalloc(sizeof *priv, GFP_KERNEL);
463 if (!priv) 463 if (!priv)
464 return -ENOMEM; 464 return -ENOMEM;
465 465
@@ -536,7 +536,7 @@ static int __devinit dataflash_probe(struct spi_device *spi)
536 if (status <= 0 || status == 0xff) { 536 if (status <= 0 || status == 0xff) {
537 DEBUG(MTD_DEBUG_LEVEL1, "%s: status error %d\n", 537 DEBUG(MTD_DEBUG_LEVEL1, "%s: status error %d\n",
538 spi->dev.bus_id, status); 538 spi->dev.bus_id, status);
539 if (status == 0xff) 539 if (status == 0 || status == 0xff)
540 status = -ENODEV; 540 status = -ENODEV;
541 return status; 541 return status;
542 } 542 }
diff --git a/drivers/mtd/maps/Kconfig b/drivers/mtd/maps/Kconfig
index 3a33b98eb93d..f457315579db 100644
--- a/drivers/mtd/maps/Kconfig
+++ b/drivers/mtd/maps/Kconfig
@@ -590,7 +590,7 @@ config MTD_BAST_MAXSIZE
590 default "4" 590 default "4"
591 591
592config MTD_SHARP_SL 592config MTD_SHARP_SL
593 bool "ROM maped on Sharp SL Series" 593 bool "ROM mapped on Sharp SL Series"
594 depends on MTD && ARCH_PXA 594 depends on MTD && ARCH_PXA
595 help 595 help
596 This enables access to the flash chip on the Sharp SL Series of PDAs. 596 This enables access to the flash chip on the Sharp SL Series of PDAs.
diff --git a/drivers/mtd/maps/cfi_flagadm.c b/drivers/mtd/maps/cfi_flagadm.c
index 92b5d883d7b0..65e5ee552010 100644
--- a/drivers/mtd/maps/cfi_flagadm.c
+++ b/drivers/mtd/maps/cfi_flagadm.c
@@ -80,7 +80,7 @@ struct mtd_partition flagadm_parts[] = {
80 .size = FLASH_PARTITION2_SIZE 80 .size = FLASH_PARTITION2_SIZE
81 }, 81 },
82 { 82 {
83 .name = "Persistant storage", 83 .name = "Persistent storage",
84 .offset = FLASH_PARTITION3_ADDR, 84 .offset = FLASH_PARTITION3_ADDR,
85 .size = FLASH_PARTITION3_SIZE 85 .size = FLASH_PARTITION3_SIZE
86 } 86 }
diff --git a/drivers/mtd/rfd_ftl.c b/drivers/mtd/rfd_ftl.c
index d60cc6696cbd..d4b1ba8f23ef 100644
--- a/drivers/mtd/rfd_ftl.c
+++ b/drivers/mtd/rfd_ftl.c
@@ -768,7 +768,7 @@ static void rfd_ftl_add_mtd(struct mtd_blktrans_ops *tr, struct mtd_info *mtd)
768 if (mtd->type != MTD_NORFLASH) 768 if (mtd->type != MTD_NORFLASH)
769 return; 769 return;
770 770
771 part = kcalloc(1, sizeof(struct partition), GFP_KERNEL); 771 part = kzalloc(sizeof(struct partition), GFP_KERNEL);
772 if (!part) 772 if (!part)
773 return; 773 return;
774 774