diff options
author | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-03-07 06:21:16 -0500 |
---|---|---|
committer | Dominik Brodowski <linux@dominikbrodowski.net> | 2010-05-10 04:23:13 -0400 |
commit | eb14120f743d29744d9475bffec56ff4ad43a749 (patch) | |
tree | 56857094d2b0cfc0ecbd1685f18d6edbe78e140f /drivers/scsi/pcmcia/qlogic_stub.c | |
parent | a7debe789dfcaee9c4d81e5738b0be8c5d93930b (diff) |
pcmcia: re-work pcmcia_request_irq()
Instead of the old pcmcia_request_irq() interface, drivers may now
choose between:
- calling request_irq/free_irq directly. Use the IRQ from *p_dev->irq.
- use pcmcia_request_irq(p_dev, handler_t); the PCMCIA core will
clean up automatically on calls to pcmcia_disable_device() or
device ejection.
- drivers still not capable of IRQF_SHARED (or not telling us so) may
use the deprecated pcmcia_request_exclusive_irq() for the time
being; they might receive a shared IRQ nonetheless.
CC: linux-bluetooth@vger.kernel.org
CC: netdev@vger.kernel.org
CC: linux-wireless@vger.kernel.org
CC: linux-serial@vger.kernel.org
CC: alsa-devel@alsa-project.org
CC: linux-usb@vger.kernel.org
CC: linux-ide@vger.kernel.org
Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/scsi/pcmcia/qlogic_stub.c')
-rw-r--r-- | drivers/scsi/pcmcia/qlogic_stub.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/scsi/pcmcia/qlogic_stub.c b/drivers/scsi/pcmcia/qlogic_stub.c index f85f094870b4..c3a4428dbcff 100644 --- a/drivers/scsi/pcmcia/qlogic_stub.c +++ b/drivers/scsi/pcmcia/qlogic_stub.c | |||
@@ -161,7 +161,6 @@ static int qlogic_probe(struct pcmcia_device *link) | |||
161 | link->io.NumPorts1 = 16; | 161 | link->io.NumPorts1 = 16; |
162 | link->io.Attributes1 = IO_DATA_PATH_WIDTH_AUTO; | 162 | link->io.Attributes1 = IO_DATA_PATH_WIDTH_AUTO; |
163 | link->io.IOAddrLines = 10; | 163 | link->io.IOAddrLines = 10; |
164 | link->irq.Attributes = IRQ_TYPE_EXCLUSIVE; | ||
165 | link->conf.Attributes = CONF_ENABLE_IRQ; | 164 | link->conf.Attributes = CONF_ENABLE_IRQ; |
166 | link->conf.IntType = INT_MEMORY_AND_IO; | 165 | link->conf.IntType = INT_MEMORY_AND_IO; |
167 | link->conf.Present = PRESENT_OPTION; | 166 | link->conf.Present = PRESENT_OPTION; |
@@ -209,8 +208,7 @@ static int qlogic_config(struct pcmcia_device * link) | |||
209 | if (ret) | 208 | if (ret) |
210 | goto failed; | 209 | goto failed; |
211 | 210 | ||
212 | ret = pcmcia_request_irq(link, &link->irq); | 211 | if (!link->irq) |
213 | if (ret) | ||
214 | goto failed; | 212 | goto failed; |
215 | 213 | ||
216 | ret = pcmcia_request_configuration(link, &link->conf); | 214 | ret = pcmcia_request_configuration(link, &link->conf); |
@@ -227,10 +225,10 @@ static int qlogic_config(struct pcmcia_device * link) | |||
227 | /* The KXL-810AN has a bigger IO port window */ | 225 | /* The KXL-810AN has a bigger IO port window */ |
228 | if (link->io.NumPorts1 == 32) | 226 | if (link->io.NumPorts1 == 32) |
229 | host = qlogic_detect(&qlogicfas_driver_template, link, | 227 | host = qlogic_detect(&qlogicfas_driver_template, link, |
230 | link->io.BasePort1 + 16, link->irq.AssignedIRQ); | 228 | link->io.BasePort1 + 16, link->irq); |
231 | else | 229 | else |
232 | host = qlogic_detect(&qlogicfas_driver_template, link, | 230 | host = qlogic_detect(&qlogicfas_driver_template, link, |
233 | link->io.BasePort1, link->irq.AssignedIRQ); | 231 | link->io.BasePort1, link->irq); |
234 | 232 | ||
235 | if (!host) { | 233 | if (!host) { |
236 | printk(KERN_INFO "%s: no SCSI devices found\n", qlogic_name); | 234 | printk(KERN_INFO "%s: no SCSI devices found\n", qlogic_name); |
@@ -258,7 +256,7 @@ static void qlogic_release(struct pcmcia_device *link) | |||
258 | 256 | ||
259 | scsi_remove_host(info->host); | 257 | scsi_remove_host(info->host); |
260 | 258 | ||
261 | free_irq(link->irq.AssignedIRQ, info->host); | 259 | free_irq(link->irq, info->host); |
262 | pcmcia_disable_device(link); | 260 | pcmcia_disable_device(link); |
263 | 261 | ||
264 | scsi_host_put(info->host); | 262 | scsi_host_put(info->host); |