This is the pxa changes for v4.17 cycle :

- minor changes for property API
  - clock API fix for ULPI driver warning
 
 It exceptionally contains a merge from the mtd tree from Boris
 to prevent any merge conflicts in the PXA tree.
 -----BEGIN PGP SIGNATURE-----
 
 iQJLBAABCAA1FiEExgkueSa0u8n4Ls+HA/Z63R24yxIFAlqi9CMXHHJvYmVydC5q
 YXJ6bWlrQGZyZWUuZnIACgkQA/Z63R24yxIa0g//aCllCGnEY2S5+hxtg7eCAkEg
 QKqBTpHhGUDpvix8MwWrt+089Kj5CWHknx7PWQs3YQj/XzevA5mX65szteICfDX2
 K0BJj/OsecKBTCdHjVOEerM6Yy6nKrL0gX7zzUuD81H54Dk6os2pnruZEYEIn1HD
 /YhWprLs0sDqwjPI/a9Tfqw5N3nM3uStl0hp3HDplw2AtIovL/E4CrPt9Q3CCtEy
 Qj1PtM0ON9UkrlnHnFNEh3f5bja9Lwo1v3IueSoTWw8UdyxoA3itPXo+5pHZv5GG
 H4UXan1vYSaj1ISsAnOt9YuFxEMl4+d8BfKmzrqr2CAlNAeMPJRZ66UdYTecx1FJ
 z65kxxLiBi7r1eQqvBz6PhtKndHKUbBHJjc4RVJFm8PY7fzW/6LReDnHhUYpxfB1
 K5BfzfIPjH3ex9PME370gZx6wdtaepSgeQFpo2jpCI1AXO1IFEdD0v/IkQounrUe
 fgBle5yW4qQMuG+EDDOn/aDosVx7uM4856V7JtMrhUecB8fMwZ0elCaCSnchZO/G
 mOeZUa9YXUOfFVBpKdidQzVxMQBP62zd8MFKOCOIkKUjfBC9AHRn1nLkXQak8hNt
 HjRY34YqIEzbn5+3SRJO9doTV7oXMSOTfDvsQFugalhOKgHRZo7IpkREhqWWXByw
 r7vKVVY1elTGKVVWdUQ=
 =/vgG
 -----END PGP SIGNATURE-----

Merge tag 'pxa-for-4.17' of https://github.com/rjarzmik/linux into next/soc

Pull "This is the pxa changes for v4.17 cycle" from Robert Jarzmik:

 - minor changes for property API
 - clock API fix for ULPI driver warning

It exceptionally contains a merge from the mtd tree from Boris
to prevent any merge conflicts in the PXA tree.

* tag 'pxa-for-4.17' of https://github.com/rjarzmik/linux:
  ARM: pxa/raumfeld: use PROPERTY_ENTRY_U32() directly
  ARM: pxa: ulpi: fix ulpi timeout and slowpath warn
  ARM: pxa: cm-x300: remove inline directive
  ARM: pxa: fix static checker warning in pxa3xx-ulpi
  MAINTAINERS: remove entry for deleted pxa3xx_nand driver
  arm: dts: pxa: use reworked NAND controller driver
  dt-bindings: mtd: remove pxa3xx NAND controller documentation
  mtd: nand: remove useless fields from pxa3xx NAND platform data
  mtd: nand: remove deprecated pxa3xx_nand driver
  mtd: nand: use Marvell reworked NAND controller driver with all platforms
This commit is contained in:
Arnd Bergmann 2018-03-12 15:27:14 +01:00
commit fdda85f696
22 changed files with 55 additions and 2266 deletions

View File

@ -1,50 +0,0 @@
PXA3xx NAND DT bindings
Required properties:
- compatible: Should be set to one of the following:
marvell,pxa3xx-nand
marvell,armada370-nand
marvell,armada-8k-nand
- reg: The register base for the controller
- interrupts: The interrupt to map
- #address-cells: Set to <1> if the node includes partitions
- marvell,system-controller: Set to retrieve the syscon node that handles
NAND controller related registers (only required
with marvell,armada-8k-nand compatible).
Optional properties:
- dmas: dma data channel, see dma.txt binding doc
- marvell,nand-enable-arbiter: Set to enable the bus arbiter
- marvell,nand-keep-config: Set to keep the NAND controller config as set
by the bootloader
- num-cs: Number of chipselect lines to use
- nand-on-flash-bbt: boolean to enable on flash bbt option if
not present false
- nand-ecc-strength: number of bits to correct per ECC step
- nand-ecc-step-size: number of data bytes covered by a single ECC step
The following ECC strength and step size are currently supported:
- nand-ecc-strength = <1>, nand-ecc-step-size = <512>
- nand-ecc-strength = <4>, nand-ecc-step-size = <512>
- nand-ecc-strength = <8>, nand-ecc-step-size = <512>
Example:
nand0: nand@43100000 {
compatible = "marvell,pxa3xx-nand";
reg = <0x43100000 90>;
interrupts = <45>;
dmas = <&pdma 97 0>;
dma-names = "data";
#address-cells = <1>;
marvell,nand-enable-arbiter;
marvell,nand-keep-config;
num-cs = <1>;
/* partitions (optional) */
};

View File

@ -11365,12 +11365,6 @@ F: include/sound/pxa2xx-lib.h
F: sound/arm/pxa* F: sound/arm/pxa*
F: sound/soc/pxa/ F: sound/soc/pxa/
PXA3xx NAND FLASH DRIVER
M: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
L: linux-mtd@lists.infradead.org
S: Maintained
F: drivers/mtd/nand/pxa3xx_nand.c
QAT DRIVER QAT DRIVER
M: Giovanni Cabiddu <giovanni.cabiddu@intel.com> M: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
L: qat-linux@intel.com L: qat-linux@intel.com

View File

@ -117,15 +117,15 @@ pwri2c: i2c@40f500c0 {
status = "disabled"; status = "disabled";
}; };
nand0: nand@43100000 { nand_controller: nand-controller@43100000 {
compatible = "marvell,pxa3xx-nand"; compatible = "marvell,pxa3xx-nand-controller";
reg = <0x43100000 90>; reg = <0x43100000 90>;
interrupts = <45>; interrupts = <45>;
clocks = <&clks CLK_NAND>; clocks = <&clks CLK_NAND>;
dmas = <&pdma 97 3>; dmas = <&pdma 97 3>;
dma-names = "data"; dma-names = "data";
#address-cells = <1>; #address-cells = <1>;
#size-cells = <1>; #size-cells = <0>;
status = "disabled"; status = "disabled";
}; };

View File

@ -49,7 +49,7 @@ CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
CONFIG_MTD=y CONFIG_MTD=y
CONFIG_MTD_BLOCK=y CONFIG_MTD_BLOCK=y
CONFIG_MTD_NAND=y CONFIG_MTD_NAND=y
CONFIG_MTD_NAND_PXA3xx=y CONFIG_MTD_NAND_MARVELL=y
CONFIG_MTD_UBI=y CONFIG_MTD_UBI=y
CONFIG_BLK_DEV_LOOP=y CONFIG_BLK_DEV_LOOP=y
CONFIG_BLK_DEV_RAM=y CONFIG_BLK_DEV_RAM=y

View File

@ -32,8 +32,7 @@ CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
CONFIG_MTD=y CONFIG_MTD=y
CONFIG_MTD_BLOCK=y CONFIG_MTD_BLOCK=y
CONFIG_MTD_NAND=y CONFIG_MTD_NAND=y
CONFIG_MTD_NAND_PXA3xx=y CONFIG_MTD_NAND_MARVELL=y
CONFIG_MTD_NAND_PXA3xx_BUILTIN=y
CONFIG_MTD_ONENAND=y CONFIG_MTD_ONENAND=y
CONFIG_MTD_ONENAND_VERIFY_WRITE=y CONFIG_MTD_ONENAND_VERIFY_WRITE=y
CONFIG_MTD_ONENAND_GENERIC=y CONFIG_MTD_ONENAND_GENERIC=y

View File

@ -197,7 +197,7 @@ CONFIG_MTD_NAND_DISKONCHIP_PROBE_ADDRESS=0x4000000
CONFIG_MTD_NAND_DISKONCHIP_PROBE_HIGH=y CONFIG_MTD_NAND_DISKONCHIP_PROBE_HIGH=y
CONFIG_MTD_NAND_DISKONCHIP_BBTWRITE=y CONFIG_MTD_NAND_DISKONCHIP_BBTWRITE=y
CONFIG_MTD_NAND_SHARPSL=m CONFIG_MTD_NAND_SHARPSL=m
CONFIG_MTD_NAND_PXA3xx=m CONFIG_MTD_NAND_MARVELL=m
CONFIG_MTD_NAND_CM_X270=m CONFIG_MTD_NAND_CM_X270=m
CONFIG_MTD_NAND_TMIO=m CONFIG_MTD_NAND_TMIO=m
CONFIG_MTD_NAND_BRCMNAND=m CONFIG_MTD_NAND_BRCMNAND=m

View File

@ -33,7 +33,7 @@ CONFIG_NFTL=y
CONFIG_NFTL_RW=y CONFIG_NFTL_RW=y
CONFIG_MTD_BLOCK2MTD=y CONFIG_MTD_BLOCK2MTD=y
CONFIG_MTD_NAND=y CONFIG_MTD_NAND=y
CONFIG_MTD_NAND_PXA3xx=y CONFIG_MTD_NAND_MARVELL=y
CONFIG_MTD_UBI=y CONFIG_MTD_UBI=y
CONFIG_BLK_DEV_LOOP=y CONFIG_BLK_DEV_LOOP=y
CONFIG_ISL29003=y CONFIG_ISL29003=y

View File

@ -172,10 +172,8 @@ static struct mtd_partition aspenite_nand_partitions[] = {
}; };
static struct pxa3xx_nand_platform_data aspenite_nand_info = { static struct pxa3xx_nand_platform_data aspenite_nand_info = {
.enable_arbiter = 1, .parts = aspenite_nand_partitions,
.num_cs = 1, .nr_parts = ARRAY_SIZE(aspenite_nand_partitions),
.parts[0] = aspenite_nand_partitions,
.nr_parts[0] = ARRAY_SIZE(aspenite_nand_partitions),
}; };
static struct i2c_board_info aspenite_i2c_info[] __initdata = { static struct i2c_board_info aspenite_i2c_info[] __initdata = {

View File

@ -178,11 +178,8 @@ static struct mv_usb_platform_data ttc_usb_pdata = {
#endif #endif
#endif #endif
#if IS_ENABLED(CONFIG_MTD_NAND_PXA3xx) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
static struct pxa3xx_nand_platform_data dkb_nand_info = { static struct pxa3xx_nand_platform_data dkb_nand_info = {};
.enable_arbiter = 1,
.num_cs = 1,
};
#endif #endif
#if IS_ENABLED(CONFIG_MMP_DISP) #if IS_ENABLED(CONFIG_MMP_DISP)
@ -275,7 +272,7 @@ static void __init ttc_dkb_init(void)
/* on-chip devices */ /* on-chip devices */
pxa910_add_uart(1); pxa910_add_uart(1);
#if IS_ENABLED(CONFIG_MTD_NAND_PXA3xx) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
pxa910_add_nand(&dkb_nand_info); pxa910_add_nand(&dkb_nand_info);
#endif #endif

View File

@ -391,7 +391,7 @@ static void __init cm_x300_init_ac97(void)
static inline void cm_x300_init_ac97(void) {} static inline void cm_x300_init_ac97(void) {}
#endif #endif
#if defined(CONFIG_MTD_NAND_PXA3xx) || defined(CONFIG_MTD_NAND_PXA3xx_MODULE) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
static struct mtd_partition cm_x300_nand_partitions[] = { static struct mtd_partition cm_x300_nand_partitions[] = {
[0] = { [0] = {
.name = "OBM", .name = "OBM",
@ -429,11 +429,9 @@ static struct mtd_partition cm_x300_nand_partitions[] = {
}; };
static struct pxa3xx_nand_platform_data cm_x300_nand_info = { static struct pxa3xx_nand_platform_data cm_x300_nand_info = {
.enable_arbiter = 1,
.keep_config = 1, .keep_config = 1,
.num_cs = 1, .parts = cm_x300_nand_partitions,
.parts[0] = cm_x300_nand_partitions, .nr_parts = ARRAY_SIZE(cm_x300_nand_partitions),
.nr_parts[0] = ARRAY_SIZE(cm_x300_nand_partitions),
}; };
static void __init cm_x300_init_nand(void) static void __init cm_x300_init_nand(void)
@ -509,7 +507,7 @@ static int cm_x300_ulpi_phy_reset(void)
return 0; return 0;
} }
static inline int cm_x300_u2d_init(struct device *dev) static int cm_x300_u2d_init(struct device *dev)
{ {
int err = 0; int err = 0;
@ -521,7 +519,7 @@ static inline int cm_x300_u2d_init(struct device *dev)
pr_err("failed to get CLK_POUT: %d\n", err); pr_err("failed to get CLK_POUT: %d\n", err);
return err; return err;
} }
clk_enable(pout_clk); clk_prepare_enable(pout_clk);
err = cm_x300_ulpi_phy_reset(); err = cm_x300_ulpi_phy_reset();
if (err) { if (err) {
@ -536,7 +534,7 @@ static inline int cm_x300_u2d_init(struct device *dev)
static void cm_x300_u2d_exit(struct device *dev) static void cm_x300_u2d_exit(struct device *dev)
{ {
if (cpu_is_pxa310()) { if (cpu_is_pxa310()) {
clk_disable(pout_clk); clk_disable_unprepare(pout_clk);
clk_put(pout_clk); clk_put(pout_clk);
} }
} }

View File

@ -110,7 +110,7 @@ void __init colibri_pxa3xx_init_lcd(int bl_pin)
} }
#endif #endif
#if defined(CONFIG_MTD_NAND_PXA3xx) || defined(CONFIG_MTD_NAND_PXA3xx_MODULE) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
static struct mtd_partition colibri_nand_partitions[] = { static struct mtd_partition colibri_nand_partitions[] = {
{ {
.name = "bootloader", .name = "bootloader",
@ -138,11 +138,9 @@ static struct mtd_partition colibri_nand_partitions[] = {
}; };
static struct pxa3xx_nand_platform_data colibri_nand_info = { static struct pxa3xx_nand_platform_data colibri_nand_info = {
.enable_arbiter = 1,
.keep_config = 1, .keep_config = 1,
.num_cs = 1, .parts = colibri_nand_partitions,
.parts[0] = colibri_nand_partitions, .nr_parts = ARRAY_SIZE(colibri_nand_partitions),
.nr_parts[0] = ARRAY_SIZE(colibri_nand_partitions),
}; };
void __init colibri_pxa3xx_init_nand(void) void __init colibri_pxa3xx_init_nand(void)

View File

@ -46,7 +46,7 @@ static inline void colibri_pxa3xx_init_lcd(int bl_pin) {}
extern void colibri_pxa3xx_init_eth(struct ax_plat_data *plat_data); extern void colibri_pxa3xx_init_eth(struct ax_plat_data *plat_data);
#endif #endif
#if defined(CONFIG_MTD_NAND_PXA3xx) || defined(CONFIG_MTD_NAND_PXA3xx_MODULE) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
extern void colibri_pxa3xx_init_nand(void); extern void colibri_pxa3xx_init_nand(void);
#else #else
static inline void colibri_pxa3xx_init_nand(void) {} static inline void colibri_pxa3xx_init_nand(void) {}

View File

@ -291,7 +291,7 @@ static void __init littleton_init_mmc(void)
static inline void littleton_init_mmc(void) {} static inline void littleton_init_mmc(void) {}
#endif #endif
#if defined(CONFIG_MTD_NAND_PXA3xx) || defined(CONFIG_MTD_NAND_PXA3xx_MODULE) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
static struct mtd_partition littleton_nand_partitions[] = { static struct mtd_partition littleton_nand_partitions[] = {
[0] = { [0] = {
.name = "Bootloader", .name = "Bootloader",
@ -329,10 +329,8 @@ static struct mtd_partition littleton_nand_partitions[] = {
}; };
static struct pxa3xx_nand_platform_data littleton_nand_info = { static struct pxa3xx_nand_platform_data littleton_nand_info = {
.enable_arbiter = 1, .parts = littleton_nand_partitions,
.num_cs = 1, .nr_parts = ARRAY_SIZE(littleton_nand_partitions),
.parts[0] = littleton_nand_partitions,
.nr_parts[0] = ARRAY_SIZE(littleton_nand_partitions),
}; };
static void __init littleton_init_nand(void) static void __init littleton_init_nand(void)
@ -341,7 +339,7 @@ static void __init littleton_init_nand(void)
} }
#else #else
static inline void littleton_init_nand(void) {} static inline void littleton_init_nand(void) {}
#endif /* CONFIG_MTD_NAND_PXA3xx || CONFIG_MTD_NAND_PXA3xx_MODULE */ #endif /* IS_ENABLED(CONFIG_MTD_NAND_MARVELL) */
#if defined(CONFIG_I2C_PXA) || defined(CONFIG_I2C_PXA_MODULE) #if defined(CONFIG_I2C_PXA) || defined(CONFIG_I2C_PXA_MODULE)
static struct led_info littleton_da9034_leds[] = { static struct led_info littleton_da9034_leds[] = {

View File

@ -359,7 +359,7 @@ void __init mxm_8x10_ac97_init(void)
} }
/* NAND flash Support */ /* NAND flash Support */
#if defined(CONFIG_MTD_NAND_PXA3xx) || defined(CONFIG_MTD_NAND_PXA3xx_MODULE) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
#define NAND_BLOCK_SIZE SZ_128K #define NAND_BLOCK_SIZE SZ_128K
#define NB(x) (NAND_BLOCK_SIZE * (x)) #define NB(x) (NAND_BLOCK_SIZE * (x))
static struct mtd_partition mxm_8x10_nand_partitions[] = { static struct mtd_partition mxm_8x10_nand_partitions[] = {
@ -389,11 +389,9 @@ static struct mtd_partition mxm_8x10_nand_partitions[] = {
}; };
static struct pxa3xx_nand_platform_data mxm_8x10_nand_info = { static struct pxa3xx_nand_platform_data mxm_8x10_nand_info = {
.enable_arbiter = 1,
.keep_config = 1, .keep_config = 1,
.num_cs = 1, .parts = mxm_8x10_nand_partitions,
.parts[0] = mxm_8x10_nand_partitions, .nr_parts = ARRAY_SIZE(mxm_8x10_nand_partitions)
.nr_parts[0] = ARRAY_SIZE(mxm_8x10_nand_partitions)
}; };
static void __init mxm_8x10_nand_init(void) static void __init mxm_8x10_nand_init(void)
@ -402,7 +400,7 @@ static void __init mxm_8x10_nand_init(void)
} }
#else #else
static inline void mxm_8x10_nand_init(void) {} static inline void mxm_8x10_nand_init(void) {}
#endif /* CONFIG_MTD_NAND_PXA3xx || CONFIG_MTD_NAND_PXA3xx_MODULE */ #endif /* IS_ENABLED(CONFIG_MTD_NAND_MARVELL) */
/* Ethernet support: Davicom DM9000 */ /* Ethernet support: Davicom DM9000 */
static struct resource dm9k_resources[] = { static struct resource dm9k_resources[] = {

View File

@ -256,7 +256,7 @@ int pxa3xx_u2d_start_hc(struct usb_bus *host)
if (!u2d) if (!u2d)
return 0; return 0;
clk_enable(u2d->clk); clk_prepare_enable(u2d->clk);
if (cpu_is_pxa310()) { if (cpu_is_pxa310()) {
pxa310_u2d_setup_otg_hc(); pxa310_u2d_setup_otg_hc();
@ -276,7 +276,7 @@ void pxa3xx_u2d_stop_hc(struct usb_bus *host)
if (cpu_is_pxa310()) if (cpu_is_pxa310())
pxa310_stop_otg_hc(); pxa310_stop_otg_hc();
clk_disable(u2d->clk); clk_disable_unprepare(u2d->clk);
} }
EXPORT_SYMBOL_GPL(pxa3xx_u2d_stop_hc); EXPORT_SYMBOL_GPL(pxa3xx_u2d_stop_hc);
@ -331,7 +331,7 @@ static int pxa3xx_u2d_probe(struct platform_device *pdev)
goto err_free_plat; goto err_free_plat;
} }
platform_set_drvdata(pdev, &u2d); platform_set_drvdata(pdev, u2d);
return 0; return 0;

View File

@ -346,11 +346,9 @@ static struct mtd_partition raumfeld_nand_partitions[] = {
}; };
static struct pxa3xx_nand_platform_data raumfeld_nand_info = { static struct pxa3xx_nand_platform_data raumfeld_nand_info = {
.enable_arbiter = 1,
.keep_config = 1, .keep_config = 1,
.num_cs = 1, .parts = raumfeld_nand_partitions,
.parts[0] = raumfeld_nand_partitions, .nr_parts = ARRAY_SIZE(raumfeld_nand_partitions),
.nr_parts[0] = ARRAY_SIZE(raumfeld_nand_partitions),
}; };
/** /**
@ -378,9 +376,9 @@ static struct gpiod_lookup_table raumfeld_rotary_gpios_table = {
}; };
static const struct property_entry raumfeld_rotary_properties[] __initconst = { static const struct property_entry raumfeld_rotary_properties[] __initconst = {
PROPERTY_ENTRY_INTEGER("rotary-encoder,steps-per-period", u32, 24), PROPERTY_ENTRY_U32("rotary-encoder,steps-per-period", 24),
PROPERTY_ENTRY_INTEGER("linux,axis", u32, REL_X), PROPERTY_ENTRY_U32("linux,axis", REL_X),
PROPERTY_ENTRY_INTEGER("rotary-encoder,relative_axis", u32, 1), PROPERTY_ENTRY_U32("rotary-encoder,relative_axis", 1),
{ }, { },
}; };

View File

@ -338,7 +338,7 @@ static void __init zylonite_init_keypad(void)
static inline void zylonite_init_keypad(void) {} static inline void zylonite_init_keypad(void) {}
#endif #endif
#if defined(CONFIG_MTD_NAND_PXA3xx) || defined(CONFIG_MTD_NAND_PXA3xx_MODULE) #if IS_ENABLED(CONFIG_MTD_NAND_MARVELL)
static struct mtd_partition zylonite_nand_partitions[] = { static struct mtd_partition zylonite_nand_partitions[] = {
[0] = { [0] = {
.name = "Bootloader", .name = "Bootloader",
@ -376,10 +376,8 @@ static struct mtd_partition zylonite_nand_partitions[] = {
}; };
static struct pxa3xx_nand_platform_data zylonite_nand_info = { static struct pxa3xx_nand_platform_data zylonite_nand_info = {
.enable_arbiter = 1, .parts = zylonite_nand_partitions,
.num_cs = 1, .nr_parts = ARRAY_SIZE(zylonite_nand_partitions),
.parts[0] = zylonite_nand_partitions,
.nr_parts[0] = ARRAY_SIZE(zylonite_nand_partitions),
}; };
static void __init zylonite_init_nand(void) static void __init zylonite_init_nand(void)
@ -388,7 +386,7 @@ static void __init zylonite_init_nand(void)
} }
#else #else
static inline void zylonite_init_nand(void) {} static inline void zylonite_init_nand(void) {}
#endif /* CONFIG_MTD_NAND_PXA3xx || CONFIG_MTD_NAND_PXA3xx_MODULE */ #endif /* IS_ENABLED(CONFIG_MTD_NAND_MARVELL) */
#if defined(CONFIG_USB_OHCI_HCD) || defined(CONFIG_USB_OHCI_HCD_MODULE) #if defined(CONFIG_USB_OHCI_HCD) || defined(CONFIG_USB_OHCI_HCD_MODULE)
static struct pxaohci_platform_data zylonite_ohci_info = { static struct pxaohci_platform_data zylonite_ohci_info = {

View File

@ -313,17 +313,6 @@ config MTD_NAND_ATMEL
Enables support for NAND Flash / Smart Media Card interface Enables support for NAND Flash / Smart Media Card interface
on Atmel AT91 processors. on Atmel AT91 processors.
config MTD_NAND_PXA3xx
tristate "NAND support on PXA3xx and Armada 370/XP"
depends on !MTD_NAND_MARVELL
depends on PXA3xx || ARCH_MMP || PLAT_ORION || ARCH_MVEBU
help
This enables the driver for the NAND flash device found on
PXA3xx processors (NFCv1) and also on 32-bit Armada
platforms (XP, 370, 375, 38x, 39x) and 64-bit Armada
platforms (7K, 8K) (NFCv2).
config MTD_NAND_MARVELL config MTD_NAND_MARVELL
tristate "NAND controller support on Marvell boards" tristate "NAND controller support on Marvell boards"
depends on PXA3xx || ARCH_MMP || PLAT_ORION || ARCH_MVEBU || \ depends on PXA3xx || ARCH_MMP || PLAT_ORION || ARCH_MVEBU || \

View File

@ -31,7 +31,6 @@ omap2_nand-objs := omap2.o
obj-$(CONFIG_MTD_NAND_OMAP2) += omap2_nand.o obj-$(CONFIG_MTD_NAND_OMAP2) += omap2_nand.o
obj-$(CONFIG_MTD_NAND_OMAP_BCH_BUILD) += omap_elm.o obj-$(CONFIG_MTD_NAND_OMAP_BCH_BUILD) += omap_elm.o
obj-$(CONFIG_MTD_NAND_CM_X270) += cmx270_nand.o obj-$(CONFIG_MTD_NAND_CM_X270) += cmx270_nand.o
obj-$(CONFIG_MTD_NAND_PXA3xx) += pxa3xx_nand.o
obj-$(CONFIG_MTD_NAND_MARVELL) += marvell_nand.o obj-$(CONFIG_MTD_NAND_MARVELL) += marvell_nand.o
obj-$(CONFIG_MTD_NAND_TMIO) += tmio_nand.o obj-$(CONFIG_MTD_NAND_TMIO) += tmio_nand.o
obj-$(CONFIG_MTD_NAND_PLATFORM) += plat_nand.o obj-$(CONFIG_MTD_NAND_PLATFORM) += plat_nand.o

View File

@ -2520,8 +2520,7 @@ static int marvell_nand_chip_init(struct device *dev, struct marvell_nfc *nfc,
if (pdata) if (pdata)
/* Legacy bindings support only one chip */ /* Legacy bindings support only one chip */
ret = mtd_device_register(mtd, pdata->parts[0], ret = mtd_device_register(mtd, pdata->parts, pdata->nr_parts);
pdata->nr_parts[0]);
else else
ret = mtd_device_register(mtd, NULL, 0); ret = mtd_device_register(mtd, NULL, 0);
if (ret) { if (ret) {

File diff suppressed because it is too large Load Diff

View File

@ -6,41 +6,22 @@
#include <linux/mtd/partitions.h> #include <linux/mtd/partitions.h>
/* /*
* Current pxa3xx_nand controller has two chip select which * Current pxa3xx_nand controller has two chip select which both be workable but
* both be workable. * historically all platforms remaining on platform data used only one. Switch
* * to device tree if you need more.
* Notice should be taken that:
* When you want to use this feature, you should not enable the
* keep configuration feature, for two chip select could be
* attached with different nand chip. The different page size
* and timing requirement make the keep configuration impossible.
*/ */
/* The max num of chip select current support */
#define NUM_CHIP_SELECT (2)
struct pxa3xx_nand_platform_data { struct pxa3xx_nand_platform_data {
/* Keep OBM/bootloader NFC timing configuration */
/* the data flash bus is shared between the Static Memory bool keep_config;
* Controller and the Data Flash Controller, the arbiter /* Use a flash-based bad block table */
* controls the ownership of the bus bool flash_bbt;
*/ /* Requested ECC strength and ECC step size */
int enable_arbiter;
/* allow platform code to keep OBM/bootloader defined NFC config */
int keep_config;
/* indicate how many chip selects will be used */
int num_cs;
/* use an flash-based bad block table */
bool flash_bbt;
/* requested ECC strength and ECC step size */
int ecc_strength, ecc_step_size; int ecc_strength, ecc_step_size;
/* Partitions */
const struct mtd_partition *parts[NUM_CHIP_SELECT]; const struct mtd_partition *parts;
unsigned int nr_parts[NUM_CHIP_SELECT]; unsigned int nr_parts;
}; };
extern void pxa3xx_set_nand_info(struct pxa3xx_nand_platform_data *info); extern void pxa3xx_set_nand_info(struct pxa3xx_nand_platform_data *info);
#endif /* __ASM_ARCH_PXA3XX_NAND_H */ #endif /* __ASM_ARCH_PXA3XX_NAND_H */