aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn/hisax/teles_cs.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/isdn/hisax/teles_cs.c')
-rw-r--r--drivers/isdn/hisax/teles_cs.c19
1 files changed, 5 insertions, 14 deletions
diff --git a/drivers/isdn/hisax/teles_cs.c b/drivers/isdn/hisax/teles_cs.c
index 7b66038096f3..afcc2aeadb34 100644
--- a/drivers/isdn/hisax/teles_cs.c
+++ b/drivers/isdn/hisax/teles_cs.c
@@ -164,7 +164,6 @@ static int teles_probe(struct pcmcia_device *link)
164 link->conf.Attributes = CONF_ENABLE_IRQ; 164 link->conf.Attributes = CONF_ENABLE_IRQ;
165 link->conf.IntType = INT_MEMORY_AND_IO; 165 link->conf.IntType = INT_MEMORY_AND_IO;
166 166
167 link->state |= DEV_PRESENT | DEV_CONFIG_PENDING;
168 return teles_cs_config(link); 167 return teles_cs_config(link);
169} /* teles_attach */ 168} /* teles_attach */
170 169
@@ -179,17 +178,14 @@ static int teles_probe(struct pcmcia_device *link)
179 178
180static void teles_detach(struct pcmcia_device *link) 179static void teles_detach(struct pcmcia_device *link)
181{ 180{
182 local_info_t *info = link->priv; 181 local_info_t *info = link->priv;
183 182
184 DEBUG(0, "teles_detach(0x%p)\n", link); 183 DEBUG(0, "teles_detach(0x%p)\n", link);
185 184
186 if (link->state & DEV_CONFIG) { 185 info->busy = 1;
187 info->busy = 1; 186 teles_cs_release(link);
188 teles_cs_release(link);
189 }
190
191 kfree(info);
192 187
188 kfree(info);
193} /* teles_detach */ 189} /* teles_detach */
194 190
195/*====================================================================== 191/*======================================================================
@@ -253,9 +249,6 @@ static int teles_cs_config(struct pcmcia_device *link)
253 link->conf.ConfigBase = parse.config.base; 249 link->conf.ConfigBase = parse.config.base;
254 link->conf.Present = parse.config.rmask[0]; 250 link->conf.Present = parse.config.rmask[0];
255 251
256 /* Configure card */
257 link->state |= DEV_CONFIG;
258
259 tuple.TupleData = (cisdata_t *)buf; 252 tuple.TupleData = (cisdata_t *)buf;
260 tuple.TupleOffset = 0; tuple.TupleDataMax = 255; 253 tuple.TupleOffset = 0; tuple.TupleDataMax = 255;
261 tuple.Attributes = 0; 254 tuple.Attributes = 0;
@@ -319,8 +312,6 @@ static int teles_cs_config(struct pcmcia_device *link)
319 link->io.BasePort2+link->io.NumPorts2-1); 312 link->io.BasePort2+link->io.NumPorts2-1);
320 printk("\n"); 313 printk("\n");
321 314
322 link->state &= ~DEV_CONFIG_PENDING;
323
324 icard.para[0] = link->irq.AssignedIRQ; 315 icard.para[0] = link->irq.AssignedIRQ;
325 icard.para[1] = link->io.BasePort1; 316 icard.para[1] = link->io.BasePort1;
326 icard.protocol = protocol; 317 icard.protocol = protocol;