Skip to contentSkip to conversation

This patch fix the usage of the "CE don't care"-type NAND chips

PATCH New Michael Trimarchi 2 participants 2 messages Mar 15, 2011 – Mar 16, 2011

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH v3 1/1 This patch fix the usage of the "CE don't care"-type NAND chips

atmel_nand: don't require CONFIG_SYS_NAND_ENABLE_PIN If NCE is hooked up to NCS3, we don't need to (and can't) explicitly set the state of the NCE pin. Instead, the controller asserts it automatically as part of a command/data access. Only "CE don't care"-type NAND chips can be used in this manner.

Cc Scott Wood <[email protected]>
Cc Reinhard Meyer <[email protected]>

---
Change since V1
- add a better description
Change since V2:
- change commit message

drivers/mtd/nand/atmel_nand.c +2 -0
index ab8bbb3..818d362 100644
@@ -249,8 +249,10 @@ static void at91_nand_hwcontrol(struct mtd_info *mtd,
 		if (ctrl & NAND_ALE)
 			IO_ADDR_W |= CONFIG_SYS_NAND_MASK_ALE;
 
+#ifdef CONFIG_SYS_NAND_ENABLE_PIN
 		at91_set_gpio_value(CONFIG_SYS_NAND_ENABLE_PIN,
 				    !(ctrl & NAND_NCE));
+#endif
 		this->IO_ADDR_W = (void *) IO_ADDR_W;
 	}
 
#1 lore raw

PATCH v3 1/1 atmel_nand: don't require CONFIG_SYS_NAND_ENABLE_PIN

Quoted 11 lines · michael

atmel_nand: don't require CONFIG_SYS_NAND_ENABLE_PIN If NCE is hooked up to NCS3, we don't need to (and can't) explicitly set the state of the NCE pin. Instead, the controller asserts it automatically as part of a command/data access. Only "CE don't care"-type NAND chips can be used in this manner.

Cc Scott Wood <[email protected]>
Cc Reinhard Meyer <[email protected]>
Quoted 5 lines

---
Change since V1
- add a better description
Change since V2:
- change commit message

Applied to u-boot-nand-flash next, with the subject line fixed as in this e-mail.

-Scott