aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRussell King <rmk@dyn-67.arm.linux.org.uk>2007-10-02 06:28:26 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2007-10-15 13:53:47 -0400
commit693d9d95d6392074d63755b0df67865c63828fa4 (patch)
tree8edf80804ea4d4e7b2ba54509bf6a612b34baaef
parent36d8b17b4364915615aff312ba20a1b90e22b963 (diff)
[ARM] pxa: move pxa_set_mode() from pxa2xx_lubbock.c to lubbock.c
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
-rw-r--r--arch/arm/mach-pxa/lubbock.c19
-rw-r--r--drivers/pcmcia/pxa2xx_lubbock.c31
2 files changed, 20 insertions, 30 deletions
diff --git a/arch/arm/mach-pxa/lubbock.c b/arch/arm/mach-pxa/lubbock.c
index e70048fd00a5..011a1a72b61c 100644
--- a/arch/arm/mach-pxa/lubbock.c
+++ b/arch/arm/mach-pxa/lubbock.c
@@ -512,6 +512,25 @@ static void __init lubbock_map_io(void)
512 pxa_gpio_mode(GPIO44_BTCTS_MD); 512 pxa_gpio_mode(GPIO44_BTCTS_MD);
513 pxa_gpio_mode(GPIO45_BTRTS_MD); 513 pxa_gpio_mode(GPIO45_BTRTS_MD);
514 514
515 GPSR(GPIO48_nPOE) =
516 GPIO_bit(GPIO48_nPOE) |
517 GPIO_bit(GPIO49_nPWE) |
518 GPIO_bit(GPIO50_nPIOR) |
519 GPIO_bit(GPIO51_nPIOW) |
520 GPIO_bit(GPIO52_nPCE_1) |
521 GPIO_bit(GPIO53_nPCE_2);
522
523 pxa_gpio_mode(GPIO48_nPOE_MD);
524 pxa_gpio_mode(GPIO49_nPWE_MD);
525 pxa_gpio_mode(GPIO50_nPIOR_MD);
526 pxa_gpio_mode(GPIO51_nPIOW_MD);
527 pxa_gpio_mode(GPIO52_nPCE_1_MD);
528 pxa_gpio_mode(GPIO53_nPCE_2_MD);
529 pxa_gpio_mode(GPIO54_pSKTSEL_MD);
530 pxa_gpio_mode(GPIO55_nPREG_MD);
531 pxa_gpio_mode(GPIO56_nPWAIT_MD);
532 pxa_gpio_mode(GPIO57_nIOIS16_MD);
533
515 /* This is for the SMC chip select */ 534 /* This is for the SMC chip select */
516 pxa_gpio_mode(GPIO79_nCS_3_MD); 535 pxa_gpio_mode(GPIO79_nCS_3_MD);
517 536
diff --git a/drivers/pcmcia/pxa2xx_lubbock.c b/drivers/pcmcia/pxa2xx_lubbock.c
index 5e9b9a3fd027..1510d6cde3e2 100644
--- a/drivers/pcmcia/pxa2xx_lubbock.c
+++ b/drivers/pcmcia/pxa2xx_lubbock.c
@@ -30,35 +30,6 @@
30#include "sa1111_generic.h" 30#include "sa1111_generic.h"
31 31
32static int 32static int
33lubbock_pcmcia_hw_init(struct soc_pcmcia_socket *skt)
34{
35 /*
36 * Setup default state of GPIO outputs
37 * before we enable them as outputs.
38 */
39 GPSR(GPIO48_nPOE) =
40 GPIO_bit(GPIO48_nPOE) |
41 GPIO_bit(GPIO49_nPWE) |
42 GPIO_bit(GPIO50_nPIOR) |
43 GPIO_bit(GPIO51_nPIOW) |
44 GPIO_bit(GPIO52_nPCE_1) |
45 GPIO_bit(GPIO53_nPCE_2);
46
47 pxa_gpio_mode(GPIO48_nPOE_MD);
48 pxa_gpio_mode(GPIO49_nPWE_MD);
49 pxa_gpio_mode(GPIO50_nPIOR_MD);
50 pxa_gpio_mode(GPIO51_nPIOW_MD);
51 pxa_gpio_mode(GPIO52_nPCE_1_MD);
52 pxa_gpio_mode(GPIO53_nPCE_2_MD);
53 pxa_gpio_mode(GPIO54_pSKTSEL_MD);
54 pxa_gpio_mode(GPIO55_nPREG_MD);
55 pxa_gpio_mode(GPIO56_nPWAIT_MD);
56 pxa_gpio_mode(GPIO57_nIOIS16_MD);
57
58 return sa1111_pcmcia_hw_init(skt);
59}
60
61static int
62lubbock_pcmcia_configure_socket(struct soc_pcmcia_socket *skt, 33lubbock_pcmcia_configure_socket(struct soc_pcmcia_socket *skt,
63 const socket_state_t *state) 34 const socket_state_t *state)
64{ 35{
@@ -230,7 +201,7 @@ lubbock_pcmcia_configure_socket(struct soc_pcmcia_socket *skt,
230 201
231static struct pcmcia_low_level lubbock_pcmcia_ops = { 202static struct pcmcia_low_level lubbock_pcmcia_ops = {
232 .owner = THIS_MODULE, 203 .owner = THIS_MODULE,
233 .hw_init = lubbock_pcmcia_hw_init, 204 .hw_init = sa1111_pcmcia_hw_init,
234 .hw_shutdown = sa1111_pcmcia_hw_shutdown, 205 .hw_shutdown = sa1111_pcmcia_hw_shutdown,
235 .socket_state = sa1111_pcmcia_socket_state, 206 .socket_state = sa1111_pcmcia_socket_state,
236 .configure_socket = lubbock_pcmcia_configure_socket, 207 .configure_socket = lubbock_pcmcia_configure_socket,