From: eric@eukrea.com (Eric Bénard)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 04/13] cpuimx27 and mbimx27: allow fine control of UART4 and SDHC2 usage
Date: Wed, 19 May 2010 18:45:59 +0200 [thread overview]
Message-ID: <1274287568-30253-4-git-send-email-eric@eukrea.com> (raw)
In-Reply-To: <1274287568-30253-3-git-send-email-eric@eukrea.com>
Signed-off-by: Eric B?nard <eric@eukrea.com>
---
arch/arm/mach-mx2/Kconfig | 9 ++++++++-
arch/arm/mach-mx2/eukrea_mbimx27-baseboard.c | 8 ++++++++
arch/arm/mach-mx2/mach-cpuimx27.c | 6 ++++++
3 files changed, 22 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-mx2/Kconfig b/arch/arm/mach-mx2/Kconfig
index 742fd4e..9d3a909 100644
--- a/arch/arm/mach-mx2/Kconfig
+++ b/arch/arm/mach-mx2/Kconfig
@@ -67,9 +67,16 @@ config MACH_EUKREA_CPUIMX27_USESDHC2
bool "CPUIMX27 integrates SDHC2 module"
depends on MACH_CPUIMX27
help
- This adds support for the internal SDHC2 used on CPUIMX27 used
+ This adds support for the internal SDHC2 used on CPUIMX27
for wifi or eMMC.
+config MACH_EUKREA_CPUIMX27_USEUART4
+ bool "CPUIMX27 integrates UART4 module"
+ depends on MACH_CPUIMX27
+ help
+ This adds support for the internal UART4 used on CPUIMX27
+ for bluetooth.
+
choice
prompt "Baseboard"
depends on MACH_CPUIMX27
diff --git a/arch/arm/mach-mx2/eukrea_mbimx27-baseboard.c b/arch/arm/mach-mx2/eukrea_mbimx27-baseboard.c
index 91ab7bb..fff6c8d 100644
--- a/arch/arm/mach-mx2/eukrea_mbimx27-baseboard.c
+++ b/arch/arm/mach-mx2/eukrea_mbimx27-baseboard.c
@@ -50,10 +50,12 @@ static int eukrea_mbimx27_pins[] = {
PE10_PF_UART3_CTS,
PE11_PF_UART3_RTS,
/* UART4 */
+#if !defined(MACH_EUKREA_CPUIMX27_USEUART4)
PB26_AF_UART4_RTS,
PB28_AF_UART4_TXD,
PB29_AF_UART4_CTS,
PB31_AF_UART4_RXD,
+#endif
/* SDHC1*/
PE18_PF_SD1_D0,
PE19_PF_SD1_D1,
@@ -229,6 +231,9 @@ static struct imxuart_platform_data uart_pdata[] = {
{
.flags = IMXUART_HAVE_RTSCTS,
},
+ {
+ .flags = IMXUART_HAVE_RTSCTS,
+ },
};
#if defined(CONFIG_TOUCHSCREEN_ADS7846)
@@ -293,6 +298,9 @@ void __init eukrea_mbimx27_baseboard_init(void)
mxc_register_device(&mxc_uart_device1, &uart_pdata[0]);
mxc_register_device(&mxc_uart_device2, &uart_pdata[1]);
+#if !defined(MACH_EUKREA_CPUIMX27_USEUART4)
+ mxc_register_device(&mxc_uart_device3, &uart_pdata[2]);
+#endif
mxc_register_device(&mxc_fb_device, &eukrea_mbimx27_fb_data);
mxc_register_device(&mxc_sdhc_device0, NULL);
diff --git a/arch/arm/mach-mx2/mach-cpuimx27.c b/arch/arm/mach-mx2/mach-cpuimx27.c
index 1f616dc..5c6a16b 100644
--- a/arch/arm/mach-mx2/mach-cpuimx27.c
+++ b/arch/arm/mach-mx2/mach-cpuimx27.c
@@ -49,10 +49,12 @@ static int eukrea_cpuimx27_pins[] = {
PE14_PF_UART1_CTS,
PE15_PF_UART1_RTS,
/* UART4 */
+#if defined(MACH_EUKREA_CPUIMX27_USEUART4)
PB26_AF_UART4_RTS,
PB28_AF_UART4_TXD,
PB29_AF_UART4_CTS,
PB31_AF_UART4_RXD,
+#endif
/* FEC */
PD0_AIN_FEC_TXD0,
PD1_AIN_FEC_TXD1,
@@ -76,12 +78,14 @@ static int eukrea_cpuimx27_pins[] = {
PD17_PF_I2C_DATA,
PD18_PF_I2C_CLK,
/* SDHC2 */
+#if defined(CONFIG_MACH_EUKREA_CPUIMX27_USESDHC2)
PB4_PF_SD2_D0,
PB5_PF_SD2_D1,
PB6_PF_SD2_D2,
PB7_PF_SD2_D3,
PB8_PF_SD2_CMD,
PB9_PF_SD2_CLK,
+#endif
#if defined(CONFIG_SERIAL_8250) || defined(CONFIG_SERIAL_8250_MODULE)
/* Quad UART's IRQ */
GPIO_PORTD | 22 | GPIO_GPIO | GPIO_IN,
@@ -202,6 +206,8 @@ static void __init eukrea_cpuimx27_init(void)
#if defined(CONFIG_MACH_EUKREA_CPUIMX27_USESDHC2)
/* SDHC2 can be used for Wifi */
mxc_register_device(&mxc_sdhc_device1, NULL);
+#endif
+#if defined(MACH_EUKREA_CPUIMX27_USEUART4)
/* in which case UART4 is also used for Bluetooth */
mxc_register_device(&mxc_uart_device3, &uart_pdata[1]);
#endif
--
1.6.3.3
next prev parent reply other threads:[~2010-05-19 16:45 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-19 16:45 [PATCH 01/13] eukrea_mbimx27-baseboard: fix typo in display name Eric Bénard
2010-05-19 16:45 ` [PATCH 02/13] eukrea_mbimx27-baseboard: add generic-bl and platform-lcd controls Eric Bénard
2010-05-19 16:45 ` [PATCH 03/13] eukrea_mbimx27-baseboard: add timings for DVI output Eric Bénard
2010-05-19 16:45 ` Eric Bénard [this message]
2010-05-19 16:46 ` [PATCH 05/13] mach-cpuimx27: fix QuadUART's IRQ typo in pins'setup Eric Bénard
2010-05-19 16:46 ` [PATCH 06/13] eukrea_mbimx27: fix ADS7846 support Eric Bénard
2010-05-19 16:46 ` [PATCH 07/13] mach-cpuimx27: add USB Host2 and OTG support Eric Bénard
2010-05-19 16:46 ` [PATCH 08/13] mach-cpuimx27: register wdt and w1_master resources Eric Bénard
2010-05-19 16:46 ` [PATCH 09/13] mxcmmc: add card detect through DAT3 possibility Eric Bénard
2010-05-19 16:46 ` [PATCH 10/13] eukrea_mbimx27: use card detect through DAT3 for SDHC1 Eric Bénard
2010-05-19 16:46 ` [PATCH 11/13] MX2X: Add Keypad device definition for MX2X arch Eric Bénard
2010-05-19 16:46 ` [PATCH 12/13] eukrea_mbimx27: add support for the keyboard Eric Bénard
2010-05-19 16:46 ` [PATCH 13/13] mx27_defconfig: update to enable cpuimx27 & mbimx27 Eric Bénard
2010-05-19 17:11 ` [PATCH 09/13] mxcmmc: add card detect through DAT3 possibility Daniel Mack
2010-05-19 17:21 ` Eric Bénard
2010-05-19 17:23 ` Daniel Mack
2010-05-27 17:54 ` [PATCH] " Eric Bénard
2010-05-27 17:54 ` Eric Bénard
2010-05-20 6:39 ` [PATCH 06/13] eukrea_mbimx27: fix ADS7846 support Sascha Hauer
2010-05-20 7:22 ` [PATCH v2] " Eric Bénard
2010-05-20 6:33 ` [PATCH 02/13] eukrea_mbimx27-baseboard: add generic-bl and platform-lcd controls 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=1274287568-30253-4-git-send-email-eric@eukrea.com \
--to=eric@eukrea.com \
--cc=linux-arm-kernel@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.