From: "Teresa Gámez" <t.gamez@phytec.de>
To: barebox@lists.infradead.org
Subject: [PATCH 4/4] ARM: OMAP: pcm051: Create own NAND mux struct
Date: Tue, 6 Aug 2013 11:53:07 +0200 [thread overview]
Message-ID: <1375782787-494-4-git-send-email-t.gamez@phytec.de> (raw)
In-Reply-To: <1375782787-494-1-git-send-email-t.gamez@phytec.de>
NAND_WPN is not used on PCM051 so create own NAND
pin mux struct.
Signed-off-by: Teresa Gámez <t.gamez@phytec.de>
---
arch/arm/boards/pcm051/board.c | 2 +-
arch/arm/boards/pcm051/mux.c | 23 +++++++++++++++++++++++
arch/arm/boards/pcm051/mux.h | 1 +
3 files changed, 25 insertions(+), 1 deletions(-)
diff --git a/arch/arm/boards/pcm051/board.c b/arch/arm/boards/pcm051/board.c
index 1993f34..35a3a25 100644
--- a/arch/arm/boards/pcm051/board.c
+++ b/arch/arm/boards/pcm051/board.c
@@ -162,7 +162,7 @@ static void pcm051_i2c_init(void)
static void pcm051_nand_init(void)
{
- am33xx_enable_nand_pin_mux();
+ pcm051_enable_nand_pin_mux();
gpmc_generic_init(0x12);
diff --git a/arch/arm/boards/pcm051/mux.c b/arch/arm/boards/pcm051/mux.c
index 6ef5af1..89b4496 100644
--- a/arch/arm/boards/pcm051/mux.c
+++ b/arch/arm/boards/pcm051/mux.c
@@ -14,6 +14,24 @@ static const struct module_pin_mux mmc0_pin_mux[] = {
{-1},
};
+static const struct module_pin_mux nand_pin_mux[] = {
+ {OFFSET(gpmc_ad0), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD0 */
+ {OFFSET(gpmc_ad1), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD1 */
+ {OFFSET(gpmc_ad2), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD2 */
+ {OFFSET(gpmc_ad3), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD3 */
+ {OFFSET(gpmc_ad4), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD4 */
+ {OFFSET(gpmc_ad5), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD5 */
+ {OFFSET(gpmc_ad6), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD6 */
+ {OFFSET(gpmc_ad7), (MODE(0) | PULLUP_EN | RXACTIVE)}, /* NAND AD7 */
+ {OFFSET(gpmc_wait0), (MODE(0) | RXACTIVE | PULLUP_EN)}, /* NAND WAIT */
+ {OFFSET(gpmc_csn0), (MODE(0) | PULLUDEN)}, /* NAND_CS0 */
+ {OFFSET(gpmc_advn_ale), (MODE(0) | PULLUDEN)}, /* NAND_ADV_ALE */
+ {OFFSET(gpmc_oen_ren), (MODE(0) | PULLUDEN)}, /* NAND_OE */
+ {OFFSET(gpmc_wen), (MODE(0) | PULLUDEN)}, /* NAND_WEN */
+ {OFFSET(gpmc_be0n_cle), (MODE(0) | PULLUDEN)}, /* NAND_BE_CLE */
+ {-1},
+};
+
static const struct module_pin_mux user_led_pin_mux[] = {
{OFFSET(gpmc_csn1), MODE(7) | PULLUDEN}, /* USER LED1 */
{OFFSET(gpmc_csn2), MODE(7) | PULLUDEN}, /* USER LED2 */
@@ -31,6 +49,11 @@ void pcm051_enable_mmc0_pin_mux(void)
configure_module_pin_mux(mmc0_pin_mux);
}
+void pcm051_enable_nand_pin_mux(void)
+{
+ configure_module_pin_mux(nand_pin_mux);
+}
+
void pcm051_enable_user_led_pin_mux(void)
{
configure_module_pin_mux(user_led_pin_mux);
diff --git a/arch/arm/boards/pcm051/mux.h b/arch/arm/boards/pcm051/mux.h
index 4008376..5cdbe0c 100644
--- a/arch/arm/boards/pcm051/mux.h
+++ b/arch/arm/boards/pcm051/mux.h
@@ -1,3 +1,4 @@
extern void pcm051_enable_mmc0_pin_mux(void);
+extern void pcm051_enable_nand_pin_mux(void);
extern void pcm051_enable_user_led_pin_mux(void);
extern void pcm051_enable_user_btn_pin_mux(void);
--
1.7.0.4
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2013-08-06 9:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-06 9:53 [PATCH 1/4] ARM: OMAP: Pass TEXT_BASE address to mk-am35xx-spi-image Teresa Gámez
2013-08-06 9:53 ` [PATCH 2/4] ARM: OMAP: pcm051: Increase console output for MLO Teresa Gámez
2013-08-06 9:53 ` [PATCH 3/4] ARM: OMAP: pcm051: Update enviroment Teresa Gámez
2013-08-06 9:53 ` Teresa Gámez [this message]
2013-08-07 6:46 ` [PATCH 1/4] ARM: OMAP: Pass TEXT_BASE address to mk-am35xx-spi-image Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1375782787-494-4-git-send-email-t.gamez@phytec.de \
--to=t.gamez@phytec.de \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox