diff options
author | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-07-24 09:58:54 -0400 |
---|---|---|
committer | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-08-03 03:03:59 -0400 |
commit | 9a017a910346afd88ec2e065989903bf211a7d37 (patch) | |
tree | b407945c6e762f252bb81ae0fd64c745bba2ad11 /drivers/usb | |
parent | 2ce4905e4da9f512b38f56a53ece9da2072dd164 (diff) |
pcmcia: do not use io_req_t after call to pcmcia_request_io()
After pcmcia_request_io(), do not make use of the values stored in
io_req_t, but instead use those found in struct pcmcia_device->resource[].
CC: netdev@vger.kernel.org
CC: linux-wireless@vger.kernel.org
CC: linux-ide@vger.kernel.org
CC: linux-usb@vger.kernel.org
CC: laforge@gnumonks.org
CC: linux-mtd@lists.infradead.org
CC: alsa-devel@alsa-project.org
CC: linux-serial@vger.kernel.org
Acked-by: Marcel Holtmann <marcel@holtmann.org> (for drivers/bluetooth/)
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/host/sl811_cs.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/usb/host/sl811_cs.c b/drivers/usb/host/sl811_cs.c index acb7e255a837..22e04f206304 100644 --- a/drivers/usb/host/sl811_cs.c +++ b/drivers/usb/host/sl811_cs.c | |||
@@ -189,7 +189,7 @@ static int sl811_cs_config(struct pcmcia_device *link) | |||
189 | goto failed; | 189 | goto failed; |
190 | 190 | ||
191 | /* require an IRQ and two registers */ | 191 | /* require an IRQ and two registers */ |
192 | if (!link->io.NumPorts1 || link->io.NumPorts1 < 2) | 192 | if (resource_size(link->resource[0]) < 2) |
193 | goto failed; | 193 | goto failed; |
194 | 194 | ||
195 | if (!link->irq) | 195 | if (!link->irq) |
@@ -204,11 +204,10 @@ static int sl811_cs_config(struct pcmcia_device *link) | |||
204 | if (link->conf.Vpp) | 204 | if (link->conf.Vpp) |
205 | printk(", Vpp %d.%d", link->conf.Vpp/10, link->conf.Vpp%10); | 205 | printk(", Vpp %d.%d", link->conf.Vpp/10, link->conf.Vpp%10); |
206 | printk(", irq %d", link->irq); | 206 | printk(", irq %d", link->irq); |
207 | printk(", io 0x%04x-0x%04x", link->io.BasePort1, | 207 | printk(", io %pR", link->resource[0]); |
208 | link->io.BasePort1+link->io.NumPorts1-1); | ||
209 | printk("\n"); | 208 | printk("\n"); |
210 | 209 | ||
211 | if (sl811_hc_init(parent, link->io.BasePort1, link->irq) | 210 | if (sl811_hc_init(parent, link->resource[0]->start, link->irq) |
212 | < 0) { | 211 | < 0) { |
213 | failed: | 212 | failed: |
214 | printk(KERN_WARNING "sl811_cs_config failed\n"); | 213 | printk(KERN_WARNING "sl811_cs_config failed\n"); |