Skip to contentSkip to conversation

enable support for x16 NAND devices

PATCH Superseded Pekon Gupta 1 participant 4 messages Apr 3, 2014

Subsystems (3)

v3 of 5 Superseded Latest is v5 →

lore
Share & tools
lore
#0 lore raw

v3 cover enable support for x16 NAND devices

*changes v2 -> v3*
[PATCH v3 1/3] (new) porting Brian Norri's patch from linux tree
This patch allows reading of ONFI params independent of controller configuration and NAND device width.
[PATCH v3 2/2] rebase [PATCH v2 2/4] on latest release
[PATCH v3 3/3] (new) cleaned remaining GPMC_NAND_ECC_LP_xx macros from OMAP3 platform Compile Tested#> ./MAKEALL -s omap3 -s omap4 -s omap5 -s dra7xx -s am33xx

*changes v1 -> v2*
[PATCH v2 1/4]:
- dropped NAND_BUSWIDTH_AUTO, instead using CONFIG_SYS_NAND_ONFI_DETECTION
- added check in nand_flash_detect_onfi() for x8 mode
[PATCH v2 2/4]: (new) Adds CONFIG_SYS_NAND_DEVICE_WIDTH
- updated for auto-detection of bus-width in non-SPL and ONFI_DETECTION mode
Refer: http://lists.denx.de/pipermail/u-boot/2013-September/163748.html
[PATCH v2 3/4] <no update>
[PATCH v2 4/4] disabled Pulls on output only I/O pads.
- updated commit description to add details about NAND cape

*original v1*
This series includes independent patch-sets aiming to enable x16 NAND support on AM33xx boards (like beaglebone-LT).
[PATCH 1/4]: This patch is ported from linux driver/mtd/nand to allow detection
device-width of NAND by reading ONFI parameter page.
[PATCH 2/4]: enable NAND_BUSWIDTH_AUTO feature in omap_nand.c [PATCH 3/4]: cleaning of GPMC configs for NAND and NOR

Brian Norris (1):
mtd: nand: don't use read_buf for 8-bit ONFI transfers

Pekon Gupta (2):
mtd: nand: omap: add CONFIG_SYS_NAND_DEVICE_WIDTH to determine NAND
device bus-width
omap3: remove remnant macros GPMC_NAND_ECC_LP_x8_LAYOUT and

    GPMC_NAND_ECC_LP_x16_LAYOUT
 arch/arm/cpu/armv7/omap3/mem.c         | 12 ------------
 arch/arm/include/asm/arch-omap3/mem.h  |  8 --------
 board/compulab/cm_t35/cm_t35.c         | 12 ++++++------
 doc/README.nand                        |  9 +++++++++
 drivers/mtd/nand/nand_base.c           |  5 +++--
 drivers/mtd/nand/omap_gpmc.c           | 13 +++++++++----
 include/configs/am335x_evm.h           |  1 +
 include/configs/am335x_igep0033.h      |  1 +
 include/configs/am3517_crane.h         |  1 +
 include/configs/am3517_evm.h           |  1 +
 include/configs/cm_t335.h              |  2 +-
 include/configs/cm_t35.h               |  1 +
 include/configs/devkit8000.h           |  1 +
 include/configs/dig297.h               |  1 +
 include/configs/mcx.h                  |  1 +
 include/configs/omap3_beagle.h         |  1 +
 include/configs/omap3_evm_common.h     |  2 +-
 include/configs/omap3_igep00x0.h       |  1 +
 include/configs/omap3_logic.h          |  1 +
 include/configs/omap3_overo.h          |  1 +
 include/configs/omap3_pandora.h        |  2 +-
 include/configs/omap3_zoom1.h          |  1 +
 include/configs/pengwyn.h              |  2 +-
 include/configs/siemens-am33x-common.h |  1 +
 include/configs/tam3517-common.h       |  1 +
 include/configs/tao3530.h              |  2 +-
 include/configs/tricorder.h            |  1 +
 include/configs/tseries.h              |  2 +-
 28 files changed, 49 insertions(+), 38 deletions(-)
Signature · 1 line
1.8.5.1.163.gd7aced9
#1 lore raw

PATCH v3 1/3 mtd: nand: don't use read_buf for 8-bit ONFI transfers

From: Brian Norris <[email protected]>

Porting below commit from linux-tree, preserving original authorship & commit log commit bd9c6e99b58255b9de1982711ac9487c9a2f18be
Author: Brian Norris <[email protected]>
mtd: nand: don't use read_buf for 8-bit ONFI transfers

Use a repeated read_byte() instead of read_buf(), since for x16 buswidth devices, we need to avoid the upper I/O[16:9] bits. See the following commit for reference:

commit 05f7835975dad6b3b517f9e23415985e648fb875 (from linux-tree)
Author: Uwe Kleine-K?nig <[email protected]>
Date: Thu Dec 5 22:22:04 2013 +0100

mtd: nand: don't use {read,write}_buf for 8-bit transfers

Now, I think that all barriers to probing ONFI on x16 devices are removed, so remove the check from nand_flash_detect_onfi().

---
 drivers/mtd/nand/nand_base.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
drivers/mtd/nand/nand_base.c +3 -2
index 1ce55fd..5d3232c 100644
@@ -2582,7 +2582,7 @@ static int nand_flash_detect_onfi(struct mtd_info *mtd, struct nand_chip *chip,
 					int *busw)
 {
 	struct nand_onfi_params *p = &chip->onfi_params;
-	int i;
+	int i, j;
 	int val;
 
 	/* Try ONFI for unknown chip or LP */
@@ -2593,7 +2593,8 @@ static int nand_flash_detect_onfi(struct mtd_info *mtd, struct nand_chip *chip,
 
 	chip->cmdfunc(mtd, NAND_CMD_PARAM, 0, -1);
 	for (i = 0; i < 3; i++) {
-		chip->read_buf(mtd, (uint8_t *)p, sizeof(*p));
+		for (j = 0; j < sizeof(*p); j++)
+			((uint8_t *)p)[j] = chip->read_byte(mtd);
 		if (onfi_crc16(ONFI_CRC_BASE, (uint8_t *)p, 254) ==
 				le16_to_cpu(p->crc)) {
 			pr_info("ONFI param page %d valid\n", i);
Signature · 1 line
1.8.5.1.163.gd7aced9
#2 lore raw

PATCH v3 2/3 mtd: nand: omap: add CONFIG_SYS_NAND_DEVICE_WIDTH to determine NAND device bus-width

In reply to Pekon Gupta

This patch introduces CONFIG_SYS_NAND_DEVICE_WIDTH to specify bus-width of NAND device
CONFIG_SYS_NAND_DEVICE_WIDTH == 16: NAND device with x16 bus-width CONFIG_SYS_NAND_DEVICE_WIDTH == 8: NAND device with x8 bus-width

Need for a separate CONFIG_SYS_NAND_xx arise from following requirements:
(1) SPL NAND drivers does not have framework to parse ONFI parameter page.

(2) GPMC controller needs to know about the bus-width of device connected to it on board.

    But as GPMC controller is initialized before the NAND device is probed, and
    there is no way of re-configuring the GPMC controller based on-chip ONFI parameters.
    if !defined (CONFIG_SYS_NAND_SELF_INIT)
         |- board_nand_init()
         |- nand_scan()
               |- nand_scan_ident()
               |- nand_scan_tail()

(3) Non-ONFI compliant devices need some mechanism to specify device bus-width to driver.

---
 doc/README.nand                        |  9 +++++++++
 drivers/mtd/nand/omap_gpmc.c           | 13 +++++++++----
 include/configs/am335x_evm.h           |  1 +
 include/configs/am335x_igep0033.h      |  1 +
 include/configs/am3517_crane.h         |  1 +
 include/configs/am3517_evm.h           |  1 +
 include/configs/cm_t335.h              |  1 +
 include/configs/cm_t35.h               |  1 +
 include/configs/devkit8000.h           |  1 +
 include/configs/dig297.h               |  1 +
 include/configs/mcx.h                  |  1 +
 include/configs/omap3_beagle.h         |  1 +
 include/configs/omap3_evm_common.h     |  2 +-
 include/configs/omap3_igep00x0.h       |  1 +
 include/configs/omap3_logic.h          |  1 +
 include/configs/omap3_overo.h          |  1 +
 include/configs/omap3_pandora.h        |  2 +-
 include/configs/omap3_zoom1.h          |  1 +
 include/configs/pengwyn.h              |  1 +
 include/configs/siemens-am33x-common.h |  1 +
 include/configs/tam3517-common.h       |  1 +
 include/configs/tao3530.h              |  1 +
 include/configs/tricorder.h            |  1 +
 include/configs/tseries.h              |  1 +
 24 files changed, 40 insertions(+), 6 deletions(-)
doc/README.nand +9 -0
index b91f198..90d857e 100644
@@ -190,6 +190,15 @@ Configuration Options:
 	This is used by SoC platforms which do not have built-in ELM
 	hardware engine required for BCH ECC correction.
 
+   CONFIG_SYS_NAND_DEVICE_WIDTH
+	Specifies bus-width of the default NAND device connected to SoC.
+	This config is useful for driver which cannot self initialize or
+	parse ONFI parameter (like SPL drivers), or for supporting non-ONFI
+	compliant devices.
+	This config can take following values:
+	- 8: x8 NAND devices is connected
+	- 16: x16 NAND device is connected
+
 
 Platform specific options
 =========================
drivers/mtd/nand/omap_gpmc.c +9 -4
index 881a636..2933bb9 100644
@@ -805,13 +805,18 @@ int board_nand_init(struct nand_chip *nand)
 	nand->priv	= &bch_priv;
 	nand->cmd_ctrl	= omap_nand_hwcontrol;
 	nand->options	|= NAND_NO_PADDING | NAND_CACHEPRG;
-	/* If we are 16 bit dev, our gpmc config tells us that */
-	if ((readl(&gpmc_cfg->cs[cs].config1) & 0x3000) == 0x1000)
-		nand->options |= NAND_BUSWIDTH_16;
-
 	nand->chip_delay = 100;
 	nand->ecc.layout = &omap_ecclayout;
 
+	/* configure driver and controller based on NAND device bus-width */
+	gpmc_config = readl(&gpmc_cfg->cs[cs].config1);
+	if (CONFIG_SYS_NAND_DEVICE_WIDTH == 16) {
+		nand->options |= NAND_BUSWIDTH_16;
+		writel(gpmc_config | (0x1 << 12), &gpmc_cfg->cs[cs].config1);
+	} else {
+		nand->options &= ~NAND_BUSWIDTH_16;
+		writel(gpmc_config & ~(0x1 << 12), &gpmc_cfg->cs[cs].config1);
+	}
 	/* select ECC scheme */
 #if defined(CONFIG_NAND_OMAP_ECCSCHEME)
 	err = omap_select_ecc_scheme(nand, CONFIG_NAND_OMAP_ECCSCHEME,
include/configs/am335x_evm.h +1 -0
index 884a42b..c95c925 100644
@@ -229,6 +229,7 @@
 #ifdef CONFIG_NAND
 #define CONFIG_NAND_OMAP_GPMC
 #define CONFIG_NAND_OMAP_ELM
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	(CONFIG_SYS_NAND_BLOCK_SIZE / \
 					 CONFIG_SYS_NAND_PAGE_SIZE)
include/configs/am335x_igep0033.h +1 -0
index c17327f..0563935 100644
@@ -245,6 +245,7 @@
 #define CONFIG_SPL_NAND_BASE
 #define CONFIG_SPL_NAND_DRIVERS
 #define CONFIG_SPL_NAND_ECC
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	(CONFIG_SYS_NAND_BLOCK_SIZE / \
 					 CONFIG_SYS_NAND_PAGE_SIZE)
include/configs/am3517_crane.h +1 -0
index 4407b45..bc38f40 100644
@@ -329,6 +329,7 @@
 #define CONFIG_SPL_LDSCRIPT		"$(CPUDIR)/omap-common/u-boot-spl.lds"
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
include/configs/am3517_evm.h +1 -0
index 0102ff5..c57fcdd 100644
@@ -338,6 +338,7 @@
 #define CONFIG_SPL_LDSCRIPT		"$(CPUDIR)/omap-common/u-boot-spl.lds"
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
include/configs/cm_t335.h +1 -0
index 26b615b..158cf8f 100644
@@ -142,6 +142,7 @@
 
 #define CONFIG_CMD_NAND
 #define GPMC_NAND_ECC_LP_x8_LAYOUT
+#define	CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define MTDIDS_DEFAULT			"nand0=nand"
 #define MTDPARTS_DEFAULT		"mtdparts=nand:2m(spl)," \
 					"1m(u-boot),1m(u-boot-env)," \
include/configs/cm_t35.h +1 -0
index cfc4f9b..8bff334 100644
@@ -150,6 +150,7 @@
  * Board NAND Info.
  */
 #define CONFIG_SYS_NAND_QUIET_TEST
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_NAND_OMAP_GPMC
 #define CONFIG_SYS_NAND_ADDR		NAND_BASE	/* physical address */
 							/* to access nand */
include/configs/devkit8000.h +1 -0
index 16a00eb..8929bce 100644
@@ -314,6 +314,7 @@
 #define CONFIG_SPL_BSS_MAX_SIZE		0x80000
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
include/configs/dig297.h +1 -0
index af6f56b..527f9c4 100644
@@ -138,6 +138,7 @@
  * Board NAND Info.
  */
 #define CONFIG_NAND_OMAP_GPMC
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_SYS_NAND_ADDR		NAND_BASE	/* physical address */
 							/* to access nand */
 #define CONFIG_SYS_NAND_BASE		NAND_BASE	/* physical address */
include/configs/mcx.h +1 -0
index 47244c0..3804ad4 100644
@@ -382,6 +382,7 @@
 #define CONFIG_SPL_FAT_LOAD_PAYLOAD_NAME	"u-boot.img"
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
 #define CONFIG_SYS_NAND_OOBSIZE		64
include/configs/omap3_beagle.h +1 -0
index 0b57421..b31e907 100644
@@ -422,6 +422,7 @@
 #define CONFIG_SPL_LDSCRIPT		"$(CPUDIR)/omap-common/u-boot-spl.lds"
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
include/configs/omap3_evm_common.h +1 -1
index 7f3424b..8cf0dd0 100644
@@ -120,7 +120,7 @@
 
 /* Max number of NAND devices */
 #define CONFIG_SYS_MAX_NAND_DEVICE	1
-
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 /* Timeout values (in ticks) */
 #define CONFIG_SYS_FLASH_ERASE_TOUT	(100 * CONFIG_SYS_HZ)
 #define CONFIG_SYS_FLASH_WRITE_TOUT	(100 * CONFIG_SYS_HZ)
include/configs/omap3_igep00x0.h +1 -0
index d56d5b0..8b8583a 100644
@@ -187,6 +187,7 @@
 
 /* NAND boot config */
 #ifdef CONFIG_NAND
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
include/configs/omap3_logic.h +1 -0
index 0d03c75..e4c09ff 100644
@@ -141,6 +141,7 @@
 
 #define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of */
 							/* NAND devices */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_JFFS2_NAND
 /* nand device jffs2 lives on */
 #define CONFIG_JFFS2_DEV		"nand0"
include/configs/omap3_overo.h +1 -0
index 007e27f..66e753d 100644
@@ -312,6 +312,7 @@
 #define CONFIG_SPL_LDSCRIPT		"$(CPUDIR)/omap-common/u-boot-spl.lds"
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
include/configs/omap3_pandora.h +1 -1
index da67787..f6cd9b0 100644
@@ -133,7 +133,7 @@
 							/* at CS0 */
 #define CONFIG_SYS_MAX_NAND_DEVICE	1	/* Max number of NAND */
 						/* devices */
-
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #ifdef CONFIG_CMD_NAND
 #define CONFIG_CMD_MTDPARTS
 #define CONFIG_MTD_PARTITIONS
include/configs/omap3_zoom1.h +1 -0
index f0fa96e..29de928 100644
@@ -140,6 +140,7 @@
 							/* CS0 */
 #define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_JFFS2_NAND
 /* nand device jffs2 lives on */
 #define CONFIG_JFFS2_DEV		"nand0"
include/configs/pengwyn.h +1 -0
index fc25966..0a0c77f 100644
@@ -127,6 +127,7 @@
 #define CONFIG_CMD_NAND
 #define CONFIG_NAND_OMAP_GPMC
 #define CONFIG_NAND_OMAP_ELM
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	(CONFIG_SYS_NAND_BLOCK_SIZE / \
 					 CONFIG_SYS_NAND_PAGE_SIZE)
include/configs/siemens-am33x-common.h +1 -0
index 721c4e6..3920671 100644
@@ -178,6 +178,7 @@
 #define CONFIG_SPL_NAND_BASE
 #define CONFIG_SPL_NAND_DRIVERS
 #define CONFIG_SPL_NAND_ECC
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	(CONFIG_SYS_NAND_BLOCK_SIZE / \
 					 CONFIG_SYS_NAND_PAGE_SIZE)
include/configs/tam3517-common.h +1 -0
index 3522c1a..04c4b70 100644
@@ -249,6 +249,7 @@
 #define CONFIG_SPL_BSS_MAX_SIZE		0x80000
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
 #define CONFIG_SYS_NAND_OOBSIZE		64
include/configs/tao3530.h +1 -0
index 9c04c23..7dee34e 100644
@@ -141,6 +141,7 @@
 
 #define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	16
 /* Environment information */
 #define CONFIG_BOOTDELAY		3
 
include/configs/tricorder.h +1 -0
index 62f97d2..4f5d066 100644
@@ -359,6 +359,7 @@
 #define CONFIG_SPL_BSS_MAX_SIZE		0x80000
 
 /* NAND boot config */
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_PAGE_COUNT	64
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
include/configs/tseries.h +1 -0
index 8fb87ac..4c5f11a 100644
@@ -158,6 +158,7 @@
 #define CONFIG_NAND_OMAP_ELM
 #define CONFIG_NAND_OMAP_ECCSCHEME	OMAP_ECC_BCH8_CODE_HW
 #define GPMC_NAND_ECC_LP_x16_LAYOUT	1
+#define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128*1024)
 #define CONFIG_SYS_NAND_PAGE_SIZE	2048
Signature · 1 line
1.8.5.1.163.gd7aced9
#3 lore raw

PATCH v3 3/3 omap3: remove remnant macros GPMC_NAND_ECC_LP_x8_LAYOUT and GPMC_NAND_ECC_LP_x16_LAYOUT

In reply to Pekon Gupta

OMAP3 used GPMC_NAND_ECC_LP_x8_LAYOUT and GPMC_NAND_ECC_LP_x16_LAYOUT macros to configure GPMC controller for x7 or x8 bit device connected to its interface. Now this information is encoded in CONFIG_SYS_NAND_DEVICE_WIDTH macro, so above macros can be completely removed.

---
 arch/arm/cpu/armv7/omap3/mem.c        | 12 ------------
 arch/arm/include/asm/arch-omap3/mem.h |  8 --------
 board/compulab/cm_t35/cm_t35.c        | 12 ++++++------
 include/configs/cm_t335.h             |  1 -
 include/configs/pengwyn.h             |  1 -
 include/configs/tao3530.h             |  1 -
 include/configs/tseries.h             |  1 -
 7 files changed, 6 insertions(+), 30 deletions(-)
arch/arm/cpu/armv7/omap3/mem.c +0 -12
index e649409..1832aff 100644
@@ -21,17 +21,6 @@
 struct gpmc *gpmc_cfg;
 
 #if defined(CONFIG_CMD_NAND)
-#if defined(GPMC_NAND_ECC_SP_x8_LAYOUT) || defined(GPMC_NAND_ECC_LP_x8_LAYOUT)
-static const u32 gpmc_m_nand[GPMC_MAX_REG] = {
-	SMNAND_GPMC_CONFIG1,
-	SMNAND_GPMC_CONFIG2,
-	SMNAND_GPMC_CONFIG3,
-	SMNAND_GPMC_CONFIG4,
-	SMNAND_GPMC_CONFIG5,
-	SMNAND_GPMC_CONFIG6,
-	0,
-};
-#else
 static const u32 gpmc_m_nand[GPMC_MAX_REG] = {
 	M_NAND_GPMC_CONFIG1,
 	M_NAND_GPMC_CONFIG2,
@@ -40,7 +29,6 @@ static const u32 gpmc_m_nand[GPMC_MAX_REG] = {
 	M_NAND_GPMC_CONFIG5,
 	M_NAND_GPMC_CONFIG6, 0
 };
-#endif
 #endif /* CONFIG_CMD_NAND */
 
 #if defined(CONFIG_CMD_ONENAND)
arch/arm/include/asm/arch-omap3/mem.h +0 -8
index 1804191..d90fe16 100644
@@ -353,14 +353,6 @@ enum {
 
 #define GPMC_CS_ENABLE		0x1
 
-#define SMNAND_GPMC_CONFIG1	0x00000800
-#define SMNAND_GPMC_CONFIG2	0x00141400
-#define SMNAND_GPMC_CONFIG3	0x00141400
-#define SMNAND_GPMC_CONFIG4	0x0F010F01
-#define SMNAND_GPMC_CONFIG5	0x010C1414
-#define SMNAND_GPMC_CONFIG6	0x1F0F0A80
-#define SMNAND_GPMC_CONFIG7	0x00000C44
-
 #define M_NAND_GPMC_CONFIG1	0x00001800
 #define M_NAND_GPMC_CONFIG2	0x00141400
 #define M_NAND_GPMC_CONFIG3	0x00141400
board/compulab/cm_t35/cm_t35.c +6 -6
index 00bcf41..0944903 100644
@@ -54,12 +54,12 @@ static u32 gpmc_net_config[GPMC_MAX_REG] = {
 };
 
 static u32 gpmc_nand_config[GPMC_MAX_REG] = {
-	SMNAND_GPMC_CONFIG1,
-	SMNAND_GPMC_CONFIG2,
-	SMNAND_GPMC_CONFIG3,
-	SMNAND_GPMC_CONFIG4,
-	SMNAND_GPMC_CONFIG5,
-	SMNAND_GPMC_CONFIG6,
+	M_NAND_GPMC_CONFIG1,
+	M_NAND_GPMC_CONFIG2,
+	M_NAND_GPMC_CONFIG3,
+	M_NAND_GPMC_CONFIG4,
+	M_NAND_GPMC_CONFIG5,
+	M_NAND_GPMC_CONFIG6,
 	0,
 };
 
include/configs/cm_t335.h +0 -1
index 158cf8f..850f3b0 100644
@@ -141,7 +141,6 @@
 #define CONFIG_SYS_NAND_U_BOOT_OFFS	0x200000
 
 #define CONFIG_CMD_NAND
-#define GPMC_NAND_ECC_LP_x8_LAYOUT
 #define	CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define MTDIDS_DEFAULT			"nand0=nand"
 #define MTDPARTS_DEFAULT		"mtdparts=nand:2m(spl)," \
include/configs/pengwyn.h +0 -1
index 0a0c77f..289628a 100644
@@ -150,7 +150,6 @@
 #define CONFIG_SYS_NAND_U_BOOT_START	CONFIG_SYS_TEXT_BASE
 #define CONFIG_SYS_NAND_U_BOOT_OFFS	0x80000
 
-#define GPMC_NAND_ECC_LP_x8_LAYOUT	1
 #define MTDIDS_DEFAULT			"nand0=omap2-nand.0"
 #define MTDPARTS_DEFAULT		"mtdparts=omap2-nand.0:128k(SPL)," \
 					"128k(SPL.backup1)," \
include/configs/tao3530.h +0 -1
index 7dee34e..689a8a3 100644
@@ -137,7 +137,6 @@
 #define CONFIG_SYS_NAND_BASE		NAND_BASE	/* physical address */
 							/* to access nand at */
 							/* CS0 */
-#define GPMC_NAND_ECC_LP_x16_LAYOUT
 
 #define CONFIG_SYS_MAX_NAND_DEVICE	1		/* Max number of NAND */
 							/* devices */
include/configs/tseries.h +0 -1
index 4c5f11a..764e3b4 100644
@@ -157,7 +157,6 @@
 /* don't change OMAP_ELM, ECCSCHEME. ROM code only supports this */
 #define CONFIG_NAND_OMAP_ELM
 #define CONFIG_NAND_OMAP_ECCSCHEME	OMAP_ECC_BCH8_CODE_HW
-#define GPMC_NAND_ECC_LP_x16_LAYOUT	1
 #define CONFIG_SYS_NAND_DEVICE_WIDTH	8
 #define CONFIG_SYS_NAND_5_ADDR_CYCLE
 #define CONFIG_SYS_NAND_BLOCK_SIZE	(128*1024)
Signature · 1 line
1.8.5.1.163.gd7aced9