diff options
Diffstat (limited to 'drivers/isdn/hisax/elsa_cs.c')
-rw-r--r-- | drivers/isdn/hisax/elsa_cs.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/isdn/hisax/elsa_cs.c b/drivers/isdn/hisax/elsa_cs.c index 00835d537c10..bcda675e9103 100644 --- a/drivers/isdn/hisax/elsa_cs.c +++ b/drivers/isdn/hisax/elsa_cs.c | |||
@@ -121,7 +121,7 @@ static void elsa_cs_detach(struct pcmcia_device *p_dev); | |||
121 | */ | 121 | */ |
122 | 122 | ||
123 | typedef struct local_info_t { | 123 | typedef struct local_info_t { |
124 | dev_link_t link; | 124 | struct pcmcia_device *p_dev; |
125 | dev_node_t node; | 125 | dev_node_t node; |
126 | int busy; | 126 | int busy; |
127 | int cardnr; | 127 | int cardnr; |
@@ -141,8 +141,8 @@ typedef struct local_info_t { | |||
141 | 141 | ||
142 | static int elsa_cs_attach(struct pcmcia_device *p_dev) | 142 | static int elsa_cs_attach(struct pcmcia_device *p_dev) |
143 | { | 143 | { |
144 | dev_link_t *link; | ||
145 | local_info_t *local; | 144 | local_info_t *local; |
145 | dev_link_t *link = dev_to_instance(p_dev); | ||
146 | 146 | ||
147 | DEBUG(0, "elsa_cs_attach()\n"); | 147 | DEBUG(0, "elsa_cs_attach()\n"); |
148 | 148 | ||
@@ -150,8 +150,11 @@ static int elsa_cs_attach(struct pcmcia_device *p_dev) | |||
150 | local = kmalloc(sizeof(local_info_t), GFP_KERNEL); | 150 | local = kmalloc(sizeof(local_info_t), GFP_KERNEL); |
151 | if (!local) return -ENOMEM; | 151 | if (!local) return -ENOMEM; |
152 | memset(local, 0, sizeof(local_info_t)); | 152 | memset(local, 0, sizeof(local_info_t)); |
153 | |||
154 | local->p_dev = p_dev; | ||
155 | link->priv = local; | ||
156 | |||
153 | local->cardnr = -1; | 157 | local->cardnr = -1; |
154 | link = &local->link; link->priv = local; | ||
155 | 158 | ||
156 | /* Interrupt setup */ | 159 | /* Interrupt setup */ |
157 | link->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING|IRQ_FIRST_SHARED; | 160 | link->irq.Attributes = IRQ_TYPE_DYNAMIC_SHARING|IRQ_FIRST_SHARED; |
@@ -172,9 +175,6 @@ static int elsa_cs_attach(struct pcmcia_device *p_dev) | |||
172 | link->conf.Attributes = CONF_ENABLE_IRQ; | 175 | link->conf.Attributes = CONF_ENABLE_IRQ; |
173 | link->conf.IntType = INT_MEMORY_AND_IO; | 176 | link->conf.IntType = INT_MEMORY_AND_IO; |
174 | 177 | ||
175 | link->handle = p_dev; | ||
176 | p_dev->instance = link; | ||
177 | |||
178 | link->state |= DEV_PRESENT | DEV_CONFIG_PENDING; | 178 | link->state |= DEV_PRESENT | DEV_CONFIG_PENDING; |
179 | elsa_cs_config(link); | 179 | elsa_cs_config(link); |
180 | 180 | ||
@@ -320,7 +320,7 @@ static void elsa_cs_config(dev_link_t *link) | |||
320 | sprintf(dev->node.dev_name, "elsa"); | 320 | sprintf(dev->node.dev_name, "elsa"); |
321 | dev->node.major = dev->node.minor = 0x0; | 321 | dev->node.major = dev->node.minor = 0x0; |
322 | 322 | ||
323 | link->dev = &dev->node; | 323 | link->dev_node = &dev->node; |
324 | 324 | ||
325 | /* Finally, report what we've done */ | 325 | /* Finally, report what we've done */ |
326 | printk(KERN_INFO "%s: index 0x%02x: ", | 326 | printk(KERN_INFO "%s: index 0x%02x: ", |