diff options
Diffstat (limited to 'drivers/net/pcmcia/3c589_cs.c')
-rw-r--r-- | drivers/net/pcmcia/3c589_cs.c | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/drivers/net/pcmcia/3c589_cs.c b/drivers/net/pcmcia/3c589_cs.c index 565063d49334..160d48a8ed88 100644 --- a/drivers/net/pcmcia/3c589_cs.c +++ b/drivers/net/pcmcia/3c589_cs.c | |||
@@ -142,7 +142,7 @@ DRV_NAME ".c " DRV_VERSION " 2001/10/13 00:08:50 (David Hinds)"; | |||
142 | 142 | ||
143 | /*====================================================================*/ | 143 | /*====================================================================*/ |
144 | 144 | ||
145 | static void tc589_config(struct pcmcia_device *link); | 145 | static int tc589_config(struct pcmcia_device *link); |
146 | static void tc589_release(struct pcmcia_device *link); | 146 | static void tc589_release(struct pcmcia_device *link); |
147 | 147 | ||
148 | static u16 read_eeprom(kio_addr_t ioaddr, int index); | 148 | static u16 read_eeprom(kio_addr_t ioaddr, int index); |
@@ -170,7 +170,7 @@ static void tc589_detach(struct pcmcia_device *p_dev); | |||
170 | 170 | ||
171 | ======================================================================*/ | 171 | ======================================================================*/ |
172 | 172 | ||
173 | static int tc589_attach(struct pcmcia_device *link) | 173 | static int tc589_probe(struct pcmcia_device *link) |
174 | { | 174 | { |
175 | struct el3_private *lp; | 175 | struct el3_private *lp; |
176 | struct net_device *dev; | 176 | struct net_device *dev; |
@@ -212,9 +212,7 @@ static int tc589_attach(struct pcmcia_device *link) | |||
212 | SET_ETHTOOL_OPS(dev, &netdev_ethtool_ops); | 212 | SET_ETHTOOL_OPS(dev, &netdev_ethtool_ops); |
213 | 213 | ||
214 | link->state |= DEV_PRESENT | DEV_CONFIG_PENDING; | 214 | link->state |= DEV_PRESENT | DEV_CONFIG_PENDING; |
215 | tc589_config(link); | 215 | return tc589_config(link); |
216 | |||
217 | return 0; | ||
218 | } /* tc589_attach */ | 216 | } /* tc589_attach */ |
219 | 217 | ||
220 | /*====================================================================== | 218 | /*====================================================================== |
@@ -252,7 +250,7 @@ static void tc589_detach(struct pcmcia_device *link) | |||
252 | #define CS_CHECK(fn, ret) \ | 250 | #define CS_CHECK(fn, ret) \ |
253 | do { last_fn = (fn); if ((last_ret = (ret)) != 0) goto cs_failed; } while (0) | 251 | do { last_fn = (fn); if ((last_ret = (ret)) != 0) goto cs_failed; } while (0) |
254 | 252 | ||
255 | static void tc589_config(struct pcmcia_device *link) | 253 | static int tc589_config(struct pcmcia_device *link) |
256 | { | 254 | { |
257 | struct net_device *dev = link->priv; | 255 | struct net_device *dev = link->priv; |
258 | struct el3_private *lp = netdev_priv(dev); | 256 | struct el3_private *lp = netdev_priv(dev); |
@@ -359,14 +357,13 @@ static void tc589_config(struct pcmcia_device *link) | |||
359 | printk(KERN_INFO " %dK FIFO split %s Rx:Tx, %s xcvr\n", | 357 | printk(KERN_INFO " %dK FIFO split %s Rx:Tx, %s xcvr\n", |
360 | (fifo & 7) ? 32 : 8, ram_split[(fifo >> 16) & 3], | 358 | (fifo & 7) ? 32 : 8, ram_split[(fifo >> 16) & 3], |
361 | if_names[dev->if_port]); | 359 | if_names[dev->if_port]); |
362 | return; | 360 | return 0; |
363 | 361 | ||
364 | cs_failed: | 362 | cs_failed: |
365 | cs_error(link, last_fn, last_ret); | 363 | cs_error(link, last_fn, last_ret); |
366 | failed: | 364 | failed: |
367 | tc589_release(link); | 365 | tc589_release(link); |
368 | return; | 366 | return -ENODEV; |
369 | |||
370 | } /* tc589_config */ | 367 | } /* tc589_config */ |
371 | 368 | ||
372 | /*====================================================================== | 369 | /*====================================================================== |
@@ -997,7 +994,7 @@ static struct pcmcia_driver tc589_driver = { | |||
997 | .drv = { | 994 | .drv = { |
998 | .name = "3c589_cs", | 995 | .name = "3c589_cs", |
999 | }, | 996 | }, |
1000 | .probe = tc589_attach, | 997 | .probe = tc589_probe, |
1001 | .remove = tc589_detach, | 998 | .remove = tc589_detach, |
1002 | .id_table = tc589_ids, | 999 | .id_table = tc589_ids, |
1003 | .suspend = tc589_suspend, | 1000 | .suspend = tc589_suspend, |