diff options
author | Russell King - ARM Linux <linux@arm.linux.org.uk> | 2009-03-29 14:42:44 -0400 |
---|---|---|
committer | Dominik Brodowski <linux@dominikbrodowski.net> | 2009-11-09 02:30:11 -0500 |
commit | 701a5dc05ad99a06958b3f97cb69d99b47cebee3 (patch) | |
tree | f91ab0cb2179fa771dfb3c9929bc09c7580ec3f8 /drivers/pcmcia/sa1100_neponset.c | |
parent | da4f007375197d6683461b995d404b01a7fdf2f5 (diff) |
PCMCIA: sa1111: wrap soc_pcmcia_socket to contain sa1111 specific data
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/pcmcia/sa1100_neponset.c')
-rw-r--r-- | drivers/pcmcia/sa1100_neponset.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/pcmcia/sa1100_neponset.c b/drivers/pcmcia/sa1100_neponset.c index 0c76d337815b..e39c65a06fee 100644 --- a/drivers/pcmcia/sa1100_neponset.c +++ b/drivers/pcmcia/sa1100_neponset.c | |||
@@ -43,6 +43,7 @@ | |||
43 | static int | 43 | static int |
44 | neponset_pcmcia_configure_socket(struct soc_pcmcia_socket *skt, const socket_state_t *state) | 44 | neponset_pcmcia_configure_socket(struct soc_pcmcia_socket *skt, const socket_state_t *state) |
45 | { | 45 | { |
46 | struct sa1111_pcmcia_socket *s = to_skt(skt); | ||
46 | unsigned int ncr_mask, ncr_set, pa_dwr_mask, pa_dwr_set; | 47 | unsigned int ncr_mask, ncr_set, pa_dwr_mask, pa_dwr_set; |
47 | int ret; | 48 | int ret; |
48 | 49 | ||
@@ -99,7 +100,7 @@ neponset_pcmcia_configure_socket(struct soc_pcmcia_socket *skt, const socket_sta | |||
99 | NCR_0 = (NCR_0 & ~ncr_mask) | ncr_set; | 100 | NCR_0 = (NCR_0 & ~ncr_mask) | ncr_set; |
100 | 101 | ||
101 | local_irq_restore(flags); | 102 | local_irq_restore(flags); |
102 | sa1111_set_io(SA1111_DEV(skt->dev), pa_dwr_mask, pa_dwr_set); | 103 | sa1111_set_io(s->dev, pa_dwr_mask, pa_dwr_set); |
103 | } | 104 | } |
104 | 105 | ||
105 | return 0; | 106 | return 0; |
@@ -121,6 +122,8 @@ static struct pcmcia_low_level neponset_pcmcia_ops = { | |||
121 | .configure_socket = neponset_pcmcia_configure_socket, | 122 | .configure_socket = neponset_pcmcia_configure_socket, |
122 | .socket_init = neponset_pcmcia_socket_init, | 123 | .socket_init = neponset_pcmcia_socket_init, |
123 | .socket_suspend = sa1111_pcmcia_socket_suspend, | 124 | .socket_suspend = sa1111_pcmcia_socket_suspend, |
125 | .first = 0, | ||
126 | .nr = 2, | ||
124 | }; | 127 | }; |
125 | 128 | ||
126 | int pcmcia_neponset_init(struct sa1111_dev *sadev) | 129 | int pcmcia_neponset_init(struct sa1111_dev *sadev) |
@@ -135,7 +138,9 @@ int pcmcia_neponset_init(struct sa1111_dev *sadev) | |||
135 | sa1111_set_io_dir(sadev, GPIO_A0|GPIO_A1|GPIO_A2|GPIO_A3, 0, 0); | 138 | sa1111_set_io_dir(sadev, GPIO_A0|GPIO_A1|GPIO_A2|GPIO_A3, 0, 0); |
136 | sa1111_set_io(sadev, GPIO_A0|GPIO_A1|GPIO_A2|GPIO_A3, 0); | 139 | sa1111_set_io(sadev, GPIO_A0|GPIO_A1|GPIO_A2|GPIO_A3, 0); |
137 | sa1111_set_sleep_io(sadev, GPIO_A0|GPIO_A1|GPIO_A2|GPIO_A3, 0); | 140 | sa1111_set_sleep_io(sadev, GPIO_A0|GPIO_A1|GPIO_A2|GPIO_A3, 0); |
138 | ret = sa11xx_drv_pcmcia_probe(&sadev->dev, &neponset_pcmcia_ops, 0, 2); | 141 | sa11xx_drv_pcmcia_ops(&neponset_pcmcia_ops); |
142 | ret = sa1111_pcmcia_add(sadev, &neponset_pcmcia_ops, | ||
143 | sa11xx_drv_pcmcia_add_one); | ||
139 | } | 144 | } |
140 | 145 | ||
141 | return ret; | 146 | return ret; |