All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gregory Bean <gbean@codeaurora.org>
To: dwalker@codeaurora.org
Cc: linux-arm-msm@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org, Gregory Bean <gbean@codeaurora.org>
Subject: [PATCH 3/5 v2] msm: convert 8x50 to gpiomux.
Date: Tue, 24 Aug 2010 09:58:57 -0700	[thread overview]
Message-ID: <1282669139-17640-3-git-send-email-gbean@codeaurora.org> (raw)
In-Reply-To: <1282669139-17640-1-git-send-email-gbean@codeaurora.org>

Change the gpio-init code from deprecated gpio_tlmm_config
to the new gpiomux api.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
---
 arch/arm/mach-msm/board-qsd8x50.c |   12 ------------
 arch/arm/mach-msm/gpiomux-8x50.c  |   11 ++++++++++-
 2 files changed, 10 insertions(+), 13 deletions(-)

diff --git a/arch/arm/mach-msm/board-qsd8x50.c b/arch/arm/mach-msm/board-qsd8x50.c
index e3cc807..fb0fe67 100644
--- a/arch/arm/mach-msm/board-qsd8x50.c
+++ b/arch/arm/mach-msm/board-qsd8x50.c
@@ -35,21 +35,10 @@
 
 extern struct sys_timer msm_timer;
 
-static struct msm_gpio uart3_config_data[] = {
-	{ GPIO_CFG(86, 1, GPIO_INPUT,   GPIO_PULL_DOWN, GPIO_2MA), "UART2_Rx"},
-	{ GPIO_CFG(87, 1, GPIO_OUTPUT,  GPIO_PULL_DOWN, GPIO_2MA), "UART2_Tx"},
-};
-
 static struct platform_device *devices[] __initdata = {
 	&msm_device_uart3,
 };
 
-static void msm8x50_init_uart3(void)
-{
-	msm_gpios_request_enable(uart3_config_data,
-				ARRAY_SIZE(uart3_config_data));
-}
-
 static void __init qsd8x50_map_io(void)
 {
 	msm_map_qsd8x50_io();
@@ -64,7 +53,6 @@ static void __init qsd8x50_init_irq(void)
 
 static void __init qsd8x50_init(void)
 {
-	msm8x50_init_uart3();
 	platform_add_devices(devices, ARRAY_SIZE(devices));
 }
 
diff --git a/arch/arm/mach-msm/gpiomux-8x50.c b/arch/arm/mach-msm/gpiomux-8x50.c
index 7b380b3..4406e0f 100644
--- a/arch/arm/mach-msm/gpiomux-8x50.c
+++ b/arch/arm/mach-msm/gpiomux-8x50.c
@@ -16,4 +16,13 @@
  */
 #include "gpiomux.h"
 
-struct msm_gpiomux_config msm_gpiomux_configs[GPIOMUX_NGPIOS] = {};
+struct msm_gpiomux_config msm_gpiomux_configs[GPIOMUX_NGPIOS] = {
+	[86] = { /* UART3 RX */
+		.suspended = GPIOMUX_DRV_2MA | GPIOMUX_PULL_DOWN |
+			     GPIOMUX_FUNC_1 | GPIOMUX_VALID,
+	},
+	[87] = { /* UART3 TX */
+		.suspended = GPIOMUX_DRV_2MA | GPIOMUX_PULL_DOWN |
+			     GPIOMUX_FUNC_1 | GPIOMUX_VALID,
+	},
+};
-- 
1.7.0.4

/usr2/gbean/.signature.codeaurora.org

WARNING: multiple messages have this Message-ID (diff)
From: gbean@codeaurora.org (Gregory Bean)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/5 v2] msm: convert 8x50 to gpiomux.
Date: Tue, 24 Aug 2010 09:58:57 -0700	[thread overview]
Message-ID: <1282669139-17640-3-git-send-email-gbean@codeaurora.org> (raw)
In-Reply-To: <1282669139-17640-1-git-send-email-gbean@codeaurora.org>

Change the gpio-init code from deprecated gpio_tlmm_config
to the new gpiomux api.

Signed-off-by: Gregory Bean <gbean@codeaurora.org>
---
 arch/arm/mach-msm/board-qsd8x50.c |   12 ------------
 arch/arm/mach-msm/gpiomux-8x50.c  |   11 ++++++++++-
 2 files changed, 10 insertions(+), 13 deletions(-)

diff --git a/arch/arm/mach-msm/board-qsd8x50.c b/arch/arm/mach-msm/board-qsd8x50.c
index e3cc807..fb0fe67 100644
--- a/arch/arm/mach-msm/board-qsd8x50.c
+++ b/arch/arm/mach-msm/board-qsd8x50.c
@@ -35,21 +35,10 @@
 
 extern struct sys_timer msm_timer;
 
-static struct msm_gpio uart3_config_data[] = {
-	{ GPIO_CFG(86, 1, GPIO_INPUT,   GPIO_PULL_DOWN, GPIO_2MA), "UART2_Rx"},
-	{ GPIO_CFG(87, 1, GPIO_OUTPUT,  GPIO_PULL_DOWN, GPIO_2MA), "UART2_Tx"},
-};
-
 static struct platform_device *devices[] __initdata = {
 	&msm_device_uart3,
 };
 
-static void msm8x50_init_uart3(void)
-{
-	msm_gpios_request_enable(uart3_config_data,
-				ARRAY_SIZE(uart3_config_data));
-}
-
 static void __init qsd8x50_map_io(void)
 {
 	msm_map_qsd8x50_io();
@@ -64,7 +53,6 @@ static void __init qsd8x50_init_irq(void)
 
 static void __init qsd8x50_init(void)
 {
-	msm8x50_init_uart3();
 	platform_add_devices(devices, ARRAY_SIZE(devices));
 }
 
diff --git a/arch/arm/mach-msm/gpiomux-8x50.c b/arch/arm/mach-msm/gpiomux-8x50.c
index 7b380b3..4406e0f 100644
--- a/arch/arm/mach-msm/gpiomux-8x50.c
+++ b/arch/arm/mach-msm/gpiomux-8x50.c
@@ -16,4 +16,13 @@
  */
 #include "gpiomux.h"
 
-struct msm_gpiomux_config msm_gpiomux_configs[GPIOMUX_NGPIOS] = {};
+struct msm_gpiomux_config msm_gpiomux_configs[GPIOMUX_NGPIOS] = {
+	[86] = { /* UART3 RX */
+		.suspended = GPIOMUX_DRV_2MA | GPIOMUX_PULL_DOWN |
+			     GPIOMUX_FUNC_1 | GPIOMUX_VALID,
+	},
+	[87] = { /* UART3 TX */
+		.suspended = GPIOMUX_DRV_2MA | GPIOMUX_PULL_DOWN |
+			     GPIOMUX_FUNC_1 | GPIOMUX_VALID,
+	},
+};
-- 
1.7.0.4

/usr2/gbean/.signature.codeaurora.org

  parent reply	other threads:[~2010-08-24 16:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-24 16:58 [PATCH 1/5 v2] msm: add gpiomux api for gpio multiplex & configuration Gregory Bean
2010-08-24 16:58 ` Gregory Bean
2010-08-24 16:58 ` [PATCH 2/5 v2] msm: documentation: add gpiomux documentation Gregory Bean
2010-08-24 16:58   ` Gregory Bean
2010-08-24 16:58 ` Gregory Bean [this message]
2010-08-24 16:58   ` [PATCH 3/5 v2] msm: convert 8x50 to gpiomux Gregory Bean
2010-08-24 16:58 ` [PATCH 4/5 v2] msm: convert 7x30 " Gregory Bean
2010-08-24 16:58   ` Gregory Bean
2010-08-24 16:58 ` [PATCH 5/5 v2] msm: gpio: Remove tlmm routines obsoleted by gpiomux Gregory Bean
2010-08-24 16:58   ` Gregory Bean

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=1282669139-17640-3-git-send-email-gbean@codeaurora.org \
    --to=gbean@codeaurora.org \
    --cc=dwalker@codeaurora.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.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.