diff options
author | David Woodhouse <David.Woodhouse@intel.com> | 2008-07-11 09:36:25 -0400 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2008-07-11 09:36:25 -0400 |
commit | a8931ef380c92d121ae74ecfb03b2d63f72eea6f (patch) | |
tree | 980fb6b019e11e6cb1ece55b7faff184721a8053 /drivers/mtd | |
parent | 90574d0a4d4b73308ae54a2a57a4f3f1fa98e984 (diff) | |
parent | e5a5816f7875207cb0a0a7032e39a4686c5e10a4 (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.c | 4 | ||||
-rw-r--r-- | drivers/mtd/maps/Kconfig | 9 | ||||
-rw-r--r-- | drivers/mtd/maps/Makefile | 1 | ||||
-rw-r--r-- | drivers/mtd/maps/ck804xrom.c | 18 | ||||
-rw-r--r-- | drivers/mtd/maps/mpc1211.c | 80 | ||||
-rw-r--r-- | drivers/mtd/maps/omap_nor.c | 2 | ||||
-rw-r--r-- | drivers/mtd/nand/pxa3xx_nand.c | 2 | ||||
-rw-r--r-- | drivers/mtd/onenand/generic.c | 2 | ||||
-rw-r--r-- | drivers/mtd/redboot.c | 2 |
9 files changed, 17 insertions, 103 deletions
diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c index 25efd331ef28..b402269301f6 100644 --- a/drivers/mtd/devices/m25p80.c +++ b/drivers/mtd/devices/m25p80.c | |||
@@ -346,8 +346,10 @@ static int m25p80_write(struct mtd_info *mtd, loff_t to, size_t len, | |||
346 | mutex_lock(&flash->lock); | 346 | mutex_lock(&flash->lock); |
347 | 347 | ||
348 | /* Wait until finished previous write command. */ | 348 | /* Wait until finished previous write command. */ |
349 | if (wait_till_ready(flash)) | 349 | if (wait_till_ready(flash)) { |
350 | mutex_unlock(&flash->lock); | ||
350 | return 1; | 351 | return 1; |
352 | } | ||
351 | 353 | ||
352 | write_enable(flash); | 354 | write_enable(flash); |
353 | 355 | ||
diff --git a/drivers/mtd/maps/Kconfig b/drivers/mtd/maps/Kconfig index 02c45e1e24ee..d2d339a7598d 100644 --- a/drivers/mtd/maps/Kconfig +++ b/drivers/mtd/maps/Kconfig | |||
@@ -373,7 +373,7 @@ config MTD_REDWOOD | |||
373 | 373 | ||
374 | config MTD_SOLUTIONENGINE | 374 | config MTD_SOLUTIONENGINE |
375 | tristate "CFI Flash device mapped on Hitachi SolutionEngine" | 375 | tristate "CFI Flash device mapped on Hitachi SolutionEngine" |
376 | depends on SUPERH && MTD_CFI && MTD_REDBOOT_PARTS | 376 | depends on SUPERH && SOLUTION_ENGINE && MTD_CFI && MTD_REDBOOT_PARTS |
377 | help | 377 | help |
378 | This enables access to the flash chips on the Hitachi SolutionEngine and | 378 | This enables access to the flash chips on the Hitachi SolutionEngine and |
379 | similar boards. Say 'Y' if you are building a kernel for such a board. | 379 | similar boards. Say 'Y' if you are building a kernel for such a board. |
@@ -479,13 +479,6 @@ config MTD_H720X | |||
479 | This enables access to the flash chips on the Hynix evaluation boards. | 479 | This enables access to the flash chips on the Hynix evaluation boards. |
480 | If you have such a board, say 'Y'. | 480 | If you have such a board, say 'Y'. |
481 | 481 | ||
482 | config MTD_MPC1211 | ||
483 | tristate "CFI Flash device mapped on Interface MPC-1211" | ||
484 | depends on SH_MPC1211 && MTD_CFI | ||
485 | help | ||
486 | This enables access to the flash chips on the Interface MPC-1211(CTP/PCI/MPC-SH02). | ||
487 | If you have such a board, say 'Y'. | ||
488 | |||
489 | config MTD_OMAP_NOR | 482 | config MTD_OMAP_NOR |
490 | tristate "TI OMAP board mappings" | 483 | tristate "TI OMAP board mappings" |
491 | depends on MTD_CFI && ARCH_OMAP | 484 | depends on MTD_CFI && ARCH_OMAP |
diff --git a/drivers/mtd/maps/Makefile b/drivers/mtd/maps/Makefile index d6cfce490583..f3b0c5951663 100644 --- a/drivers/mtd/maps/Makefile +++ b/drivers/mtd/maps/Makefile | |||
@@ -57,7 +57,6 @@ obj-$(CONFIG_MTD_WALNUT) += walnut.o | |||
57 | obj-$(CONFIG_MTD_H720X) += h720x-flash.o | 57 | obj-$(CONFIG_MTD_H720X) += h720x-flash.o |
58 | obj-$(CONFIG_MTD_SBC8240) += sbc8240.o | 58 | obj-$(CONFIG_MTD_SBC8240) += sbc8240.o |
59 | obj-$(CONFIG_MTD_NOR_TOTO) += omap-toto-flash.o | 59 | obj-$(CONFIG_MTD_NOR_TOTO) += omap-toto-flash.o |
60 | obj-$(CONFIG_MTD_MPC1211) += mpc1211.o | ||
61 | obj-$(CONFIG_MTD_IXP4XX) += ixp4xx.o | 60 | obj-$(CONFIG_MTD_IXP4XX) += ixp4xx.o |
62 | obj-$(CONFIG_MTD_IXP2000) += ixp2000.o | 61 | obj-$(CONFIG_MTD_IXP2000) += ixp2000.o |
63 | obj-$(CONFIG_MTD_WRSBC8260) += wr_sbc82xx_flash.o | 62 | obj-$(CONFIG_MTD_WRSBC8260) += wr_sbc82xx_flash.o |
diff --git a/drivers/mtd/maps/ck804xrom.c b/drivers/mtd/maps/ck804xrom.c index 59d8fb49270a..effaf7cdefab 100644 --- a/drivers/mtd/maps/ck804xrom.c +++ b/drivers/mtd/maps/ck804xrom.c | |||
@@ -331,15 +331,15 @@ static void __devexit ck804xrom_remove_one (struct pci_dev *pdev) | |||
331 | } | 331 | } |
332 | 332 | ||
333 | static struct pci_device_id ck804xrom_pci_tbl[] = { | 333 | static struct pci_device_id ck804xrom_pci_tbl[] = { |
334 | { PCI_VENDOR_ID_NVIDIA, 0x0051, PCI_ANY_ID, PCI_ANY_ID, DEV_CK804 }, | 334 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0051), .driver_data = DEV_CK804 }, |
335 | { PCI_VENDOR_ID_NVIDIA, 0x0360, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 335 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0360), .driver_data = DEV_MCP55 }, |
336 | { PCI_VENDOR_ID_NVIDIA, 0x0361, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 336 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0361), .driver_data = DEV_MCP55 }, |
337 | { PCI_VENDOR_ID_NVIDIA, 0x0362, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 337 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0362), .driver_data = DEV_MCP55 }, |
338 | { PCI_VENDOR_ID_NVIDIA, 0x0363, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 338 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0363), .driver_data = DEV_MCP55 }, |
339 | { PCI_VENDOR_ID_NVIDIA, 0x0364, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 339 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0364), .driver_data = DEV_MCP55 }, |
340 | { PCI_VENDOR_ID_NVIDIA, 0x0365, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 340 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0365), .driver_data = DEV_MCP55 }, |
341 | { PCI_VENDOR_ID_NVIDIA, 0x0366, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 341 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0366), .driver_data = DEV_MCP55 }, |
342 | { PCI_VENDOR_ID_NVIDIA, 0x0367, PCI_ANY_ID, PCI_ANY_ID, DEV_MCP55 }, | 342 | { PCI_DEVICE(PCI_VENDOR_ID_NVIDIA, 0x0367), .driver_data = DEV_MCP55 }, |
343 | { 0, } | 343 | { 0, } |
344 | }; | 344 | }; |
345 | 345 | ||
diff --git a/drivers/mtd/maps/mpc1211.c b/drivers/mtd/maps/mpc1211.c deleted file mode 100644 index 45a00fac88ac..000000000000 --- a/drivers/mtd/maps/mpc1211.c +++ /dev/null | |||
@@ -1,80 +0,0 @@ | |||
1 | /* | ||
2 | * Flash on MPC-1211 | ||
3 | * | ||
4 | * $Id: mpc1211.c,v 1.4 2004/09/16 23:27:13 gleixner Exp $ | ||
5 | * | ||
6 | * (C) 2002 Interface, Saito.K & Jeanne | ||
7 | * | ||
8 | * GPL'd | ||
9 | */ | ||
10 | |||
11 | #include <linux/module.h> | ||
12 | #include <linux/types.h> | ||
13 | #include <linux/kernel.h> | ||
14 | #include <asm/io.h> | ||
15 | #include <linux/mtd/mtd.h> | ||
16 | #include <linux/mtd/map.h> | ||
17 | #include <linux/mtd/partitions.h> | ||
18 | |||
19 | static struct mtd_info *flash_mtd; | ||
20 | static struct mtd_partition *parsed_parts; | ||
21 | |||
22 | struct map_info mpc1211_flash_map = { | ||
23 | .name = "MPC-1211 FLASH", | ||
24 | .size = 0x80000, | ||
25 | .bankwidth = 1, | ||
26 | }; | ||
27 | |||
28 | static struct mtd_partition mpc1211_partitions[] = { | ||
29 | { | ||
30 | .name = "IPL & ETH-BOOT", | ||
31 | .offset = 0x00000000, | ||
32 | .size = 0x10000, | ||
33 | }, | ||
34 | { | ||
35 | .name = "Flash FS", | ||
36 | .offset = 0x00010000, | ||
37 | .size = MTDPART_SIZ_FULL, | ||
38 | } | ||
39 | }; | ||
40 | |||
41 | static int __init init_mpc1211_maps(void) | ||
42 | { | ||
43 | int nr_parts; | ||
44 | |||
45 | mpc1211_flash_map.phys = 0; | ||
46 | mpc1211_flash_map.virt = (void __iomem *)P2SEGADDR(0); | ||
47 | |||
48 | simple_map_init(&mpc1211_flash_map); | ||
49 | |||
50 | printk(KERN_NOTICE "Probing for flash chips at 0x00000000:\n"); | ||
51 | flash_mtd = do_map_probe("jedec_probe", &mpc1211_flash_map); | ||
52 | if (!flash_mtd) { | ||
53 | printk(KERN_NOTICE "Flash chips not detected at either possible location.\n"); | ||
54 | return -ENXIO; | ||
55 | } | ||
56 | printk(KERN_NOTICE "MPC-1211: Flash at 0x%08lx\n", mpc1211_flash_map.virt & 0x1fffffff); | ||
57 | flash_mtd->module = THIS_MODULE; | ||
58 | |||
59 | parsed_parts = mpc1211_partitions; | ||
60 | nr_parts = ARRAY_SIZE(mpc1211_partitions); | ||
61 | |||
62 | add_mtd_partitions(flash_mtd, parsed_parts, nr_parts); | ||
63 | return 0; | ||
64 | } | ||
65 | |||
66 | static void __exit cleanup_mpc1211_maps(void) | ||
67 | { | ||
68 | if (parsed_parts) | ||
69 | del_mtd_partitions(flash_mtd); | ||
70 | else | ||
71 | del_mtd_device(flash_mtd); | ||
72 | map_destroy(flash_mtd); | ||
73 | } | ||
74 | |||
75 | module_init(init_mpc1211_maps); | ||
76 | module_exit(cleanup_mpc1211_maps); | ||
77 | |||
78 | MODULE_LICENSE("GPL"); | ||
79 | MODULE_AUTHOR("Saito.K & Jeanne <ksaito@interface.co.jp>"); | ||
80 | MODULE_DESCRIPTION("MTD map driver for MPC-1211 boards. Interface"); | ||
diff --git a/drivers/mtd/maps/omap_nor.c b/drivers/mtd/maps/omap_nor.c index 240b0e2d095d..c12d8056bebd 100644 --- a/drivers/mtd/maps/omap_nor.c +++ b/drivers/mtd/maps/omap_nor.c | |||
@@ -110,7 +110,7 @@ static int __init omapflash_probe(struct platform_device *pdev) | |||
110 | err = parse_mtd_partitions(info->mtd, part_probes, &info->parts, 0); | 110 | err = parse_mtd_partitions(info->mtd, part_probes, &info->parts, 0); |
111 | if (err > 0) | 111 | if (err > 0) |
112 | add_mtd_partitions(info->mtd, info->parts, err); | 112 | add_mtd_partitions(info->mtd, info->parts, err); |
113 | else if (err < 0 && pdata->parts) | 113 | else if (err <= 0 && pdata->parts) |
114 | add_mtd_partitions(info->mtd, pdata->parts, pdata->nr_parts); | 114 | add_mtd_partitions(info->mtd, pdata->parts, pdata->nr_parts); |
115 | else | 115 | else |
116 | #endif | 116 | #endif |
diff --git a/drivers/mtd/nand/pxa3xx_nand.c b/drivers/mtd/nand/pxa3xx_nand.c index fceb468ccdec..fe2bc7e42119 100644 --- a/drivers/mtd/nand/pxa3xx_nand.c +++ b/drivers/mtd/nand/pxa3xx_nand.c | |||
@@ -1216,7 +1216,7 @@ static int pxa3xx_nand_resume(struct platform_device *pdev) | |||
1216 | 1216 | ||
1217 | clk_enable(info->clk); | 1217 | clk_enable(info->clk); |
1218 | 1218 | ||
1219 | return pxa3xx_nand_config_flash(info); | 1219 | return pxa3xx_nand_config_flash(info, info->flash_info); |
1220 | } | 1220 | } |
1221 | #else | 1221 | #else |
1222 | #define pxa3xx_nand_suspend NULL | 1222 | #define pxa3xx_nand_suspend NULL |
diff --git a/drivers/mtd/onenand/generic.c b/drivers/mtd/onenand/generic.c index 3d44d040a47d..ad81ab8e95e2 100644 --- a/drivers/mtd/onenand/generic.c +++ b/drivers/mtd/onenand/generic.c | |||
@@ -76,7 +76,7 @@ static int __devinit generic_onenand_probe(struct device *dev) | |||
76 | err = parse_mtd_partitions(&info->mtd, part_probes, &info->parts, 0); | 76 | err = parse_mtd_partitions(&info->mtd, part_probes, &info->parts, 0); |
77 | if (err > 0) | 77 | if (err > 0) |
78 | add_mtd_partitions(&info->mtd, info->parts, err); | 78 | add_mtd_partitions(&info->mtd, info->parts, err); |
79 | else if (err < 0 && pdata->parts) | 79 | else if (err <= 0 && pdata->parts) |
80 | add_mtd_partitions(&info->mtd, pdata->parts, pdata->nr_parts); | 80 | add_mtd_partitions(&info->mtd, pdata->parts, pdata->nr_parts); |
81 | else | 81 | else |
82 | #endif | 82 | #endif |
diff --git a/drivers/mtd/redboot.c b/drivers/mtd/redboot.c index 5afa268c02f1..2d600a1bf2aa 100644 --- a/drivers/mtd/redboot.c +++ b/drivers/mtd/redboot.c | |||
@@ -293,5 +293,5 @@ module_init(redboot_parser_init); | |||
293 | module_exit(redboot_parser_exit); | 293 | module_exit(redboot_parser_exit); |
294 | 294 | ||
295 | MODULE_LICENSE("GPL"); | 295 | MODULE_LICENSE("GPL"); |
296 | MODULE_AUTHOR("Red Hat, Inc. - David Woodhouse <dwmw2@cambridge.redhat.com>"); | 296 | MODULE_AUTHOR("David Woodhouse <dwmw2@infradead.org>"); |
297 | MODULE_DESCRIPTION("Parsing code for RedBoot Flash Image System (FIS) tables"); | 297 | MODULE_DESCRIPTION("Parsing code for RedBoot Flash Image System (FIS) tables"); |