aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pcmcia/pxa2xx_palmtc.c
diff options
context:
space:
mode:
authorRussell King <rmk+kernel@arm.linux.org.uk>2012-01-13 17:56:32 -0500
committerRussell King <rmk+kernel@arm.linux.org.uk>2012-02-04 09:32:22 -0500
commita9bb5a4bf9f84256499c802fd397d56d55227e4f (patch)
tree793a74bebd0ed3f254035cb14caa093f58bb8bf6 /drivers/pcmcia/pxa2xx_palmtc.c
parentd9dc878769f521f494d1617d7cd0c92073df75d8 (diff)
PCMCIA: pxa: convert PXA socket drivers to use new irq/gpio management
Convert all the PXA platform socket drivers to use the new irq/gpio management provided by soc_common. This relieves these drivers from having to do anything with these GPIOs other than provide the numbers to soc_common. Acked-by: Dominik Brodowski <linux@dominikbrodowski.net> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'drivers/pcmcia/pxa2xx_palmtc.c')
-rw-r--r--drivers/pcmcia/pxa2xx_palmtc.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/pcmcia/pxa2xx_palmtc.c b/drivers/pcmcia/pxa2xx_palmtc.c
index 9e38de769ba3..b32d05f86789 100644
--- a/drivers/pcmcia/pxa2xx_palmtc.c
+++ b/drivers/pcmcia/pxa2xx_palmtc.c
@@ -26,7 +26,6 @@ static struct gpio palmtc_pcmcia_gpios[] = {
26 { GPIO_NR_PALMTC_PCMCIA_POWER2, GPIOF_INIT_LOW, "PCMCIA Power 2" }, 26 { GPIO_NR_PALMTC_PCMCIA_POWER2, GPIOF_INIT_LOW, "PCMCIA Power 2" },
27 { GPIO_NR_PALMTC_PCMCIA_POWER3, GPIOF_INIT_LOW, "PCMCIA Power 3" }, 27 { GPIO_NR_PALMTC_PCMCIA_POWER3, GPIOF_INIT_LOW, "PCMCIA Power 3" },
28 { GPIO_NR_PALMTC_PCMCIA_RESET, GPIOF_INIT_HIGH,"PCMCIA Reset" }, 28 { GPIO_NR_PALMTC_PCMCIA_RESET, GPIOF_INIT_HIGH,"PCMCIA Reset" },
29 { GPIO_NR_PALMTC_PCMCIA_READY, GPIOF_IN, "PCMCIA Ready" },
30 { GPIO_NR_PALMTC_PCMCIA_PWRREADY, GPIOF_IN, "PCMCIA Power Ready" }, 29 { GPIO_NR_PALMTC_PCMCIA_PWRREADY, GPIOF_IN, "PCMCIA Power Ready" },
31}; 30};
32 31
@@ -37,7 +36,8 @@ static int palmtc_pcmcia_hw_init(struct soc_pcmcia_socket *skt)
37 ret = gpio_request_array(palmtc_pcmcia_gpios, 36 ret = gpio_request_array(palmtc_pcmcia_gpios,
38 ARRAY_SIZE(palmtc_pcmcia_gpios)); 37 ARRAY_SIZE(palmtc_pcmcia_gpios));
39 38
40 skt->socket.pci_irq = gpio_to_irq(GPIO_NR_PALMTC_PCMCIA_READY); 39 skt->stat[SOC_STAT_RDY].gpio = GPIO_NR_PALMTC_PCMCIA_READY;
40 skt->stat[SOC_STAT_RDY].name = "PCMCIA Ready";
41 41
42 return ret; 42 return ret;
43} 43}
@@ -51,9 +51,6 @@ static void palmtc_pcmcia_socket_state(struct soc_pcmcia_socket *skt,
51 struct pcmcia_state *state) 51 struct pcmcia_state *state)
52{ 52{
53 state->detect = 1; /* always inserted */ 53 state->detect = 1; /* always inserted */
54 state->ready = !!gpio_get_value(GPIO_NR_PALMTC_PCMCIA_READY);
55 state->bvd1 = 1;
56 state->bvd2 = 1;
57 state->wrprot = 0; 54 state->wrprot = 0;
58 state->vs_3v = 1; 55 state->vs_3v = 1;
59 state->vs_Xv = 0; 56 state->vs_Xv = 0;