aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/pcmcia/com20020_cs.c
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2010-03-07 06:21:16 -0500
committerDominik Brodowski <linux@dominikbrodowski.net>2010-05-10 04:23:13 -0400
commiteb14120f743d29744d9475bffec56ff4ad43a749 (patch)
tree56857094d2b0cfc0ecbd1685f18d6edbe78e140f /drivers/net/pcmcia/com20020_cs.c
parenta7debe789dfcaee9c4d81e5738b0be8c5d93930b (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/net/pcmcia/com20020_cs.c')
-rw-r--r--drivers/net/pcmcia/com20020_cs.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/net/pcmcia/com20020_cs.c b/drivers/net/pcmcia/com20020_cs.c
index 21d9c9d815d1..278438beb915 100644
--- a/drivers/net/pcmcia/com20020_cs.c
+++ b/drivers/net/pcmcia/com20020_cs.c
@@ -163,7 +163,6 @@ static int com20020_probe(struct pcmcia_device *p_dev)
163 p_dev->io.Attributes1 = IO_DATA_PATH_WIDTH_8; 163 p_dev->io.Attributes1 = IO_DATA_PATH_WIDTH_8;
164 p_dev->io.NumPorts1 = 16; 164 p_dev->io.NumPorts1 = 16;
165 p_dev->io.IOAddrLines = 16; 165 p_dev->io.IOAddrLines = 16;
166 p_dev->irq.Attributes = IRQ_TYPE_EXCLUSIVE;
167 p_dev->conf.Attributes = CONF_ENABLE_IRQ; 166 p_dev->conf.Attributes = CONF_ENABLE_IRQ;
168 p_dev->conf.IntType = INT_MEMORY_AND_IO; 167 p_dev->conf.IntType = INT_MEMORY_AND_IO;
169 168
@@ -275,15 +274,14 @@ static int com20020_config(struct pcmcia_device *link)
275 dev_dbg(&link->dev, "got ioaddr %Xh\n", ioaddr); 274 dev_dbg(&link->dev, "got ioaddr %Xh\n", ioaddr);
276 275
277 dev_dbg(&link->dev, "request IRQ %d\n", 276 dev_dbg(&link->dev, "request IRQ %d\n",
278 link->irq.AssignedIRQ); 277 link->irq);
279 i = pcmcia_request_irq(link, &link->irq); 278 if (!link->irq)
280 if (i != 0)
281 { 279 {
282 dev_dbg(&link->dev, "requestIRQ failed totally!\n"); 280 dev_dbg(&link->dev, "requestIRQ failed totally!\n");
283 goto failed; 281 goto failed;
284 } 282 }
285 283
286 dev->irq = link->irq.AssignedIRQ; 284 dev->irq = link->irq;
287 285
288 ret = pcmcia_request_configuration(link, &link->conf); 286 ret = pcmcia_request_configuration(link, &link->conf);
289 if (ret) 287 if (ret)