orinoco: encapsulate driver locking
[safe/jmp/linux-2.6] / drivers / net / wireless / orinoco / spectrum_cs.c
index c609371..b4f68ef 100644 (file)
@@ -194,10 +194,8 @@ spectrum_cs_probe(struct pcmcia_device *link)
        link->priv = priv;
 
        /* Interrupt setup */
-       link->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING | IRQ_HANDLE_PRESENT;
-       link->irq.IRQInfo1 = IRQ_LEVEL_ID;
+       link->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING;
        link->irq.Handler = orinoco_interrupt;
-       link->irq.Instance = priv;
 
        /* General socket configuration defaults can go here.  In this
         * client, we assume very little, and rely on the CIS for
@@ -376,7 +374,7 @@ spectrum_cs_config(struct pcmcia_device *link)
 
        /* Register an interface with the stack */
        if (orinoco_if_add(priv, link->io.BasePort1,
-                          link->irq.AssignedIRQ) != 0) {
+                          link->irq.AssignedIRQ, NULL) != 0) {
                printk(KERN_ERR PFX "orinoco_if_add() failed\n");
                goto failed;
        }
@@ -407,9 +405,9 @@ spectrum_cs_release(struct pcmcia_device *link)
 
        /* We're committed to taking the device away now, so mark the
         * hardware as unavailable */
-       spin_lock_irqsave(&priv->lock, flags);
+       priv->hw.ops->lock_irqsave(&priv->lock, &flags);
        priv->hw_unavailable++;
-       spin_unlock_irqrestore(&priv->lock, flags);
+       priv->hw.ops->unlock_irqrestore(&priv->lock, &flags);
 
        pcmcia_disable_device(link);
        if (priv->hw.iobase)