diff options
Diffstat (limited to 'drivers/net/pcmcia/com20020_cs.c')
-rw-r--r-- | drivers/net/pcmcia/com20020_cs.c | 43 |
1 files changed, 3 insertions, 40 deletions
diff --git a/drivers/net/pcmcia/com20020_cs.c b/drivers/net/pcmcia/com20020_cs.c index f065c35cd4b7..27bfad76fc40 100644 --- a/drivers/net/pcmcia/com20020_cs.c +++ b/drivers/net/pcmcia/com20020_cs.c | |||
@@ -43,7 +43,6 @@ | |||
43 | #include <linux/arcdevice.h> | 43 | #include <linux/arcdevice.h> |
44 | #include <linux/com20020.h> | 44 | #include <linux/com20020.h> |
45 | 45 | ||
46 | #include <pcmcia/cs.h> | ||
47 | #include <pcmcia/cistpl.h> | 46 | #include <pcmcia/cistpl.h> |
48 | #include <pcmcia/ds.h> | 47 | #include <pcmcia/ds.h> |
49 | 48 | ||
@@ -119,14 +118,6 @@ typedef struct com20020_dev_t { | |||
119 | struct net_device *dev; | 118 | struct net_device *dev; |
120 | } com20020_dev_t; | 119 | } com20020_dev_t; |
121 | 120 | ||
122 | /*====================================================================== | ||
123 | |||
124 | com20020_attach() creates an "instance" of the driver, allocating | ||
125 | local data structures for one device. The device is registered | ||
126 | with Card Services. | ||
127 | |||
128 | ======================================================================*/ | ||
129 | |||
130 | static int com20020_probe(struct pcmcia_device *p_dev) | 121 | static int com20020_probe(struct pcmcia_device *p_dev) |
131 | { | 122 | { |
132 | com20020_dev_t *info; | 123 | com20020_dev_t *info; |
@@ -156,8 +147,7 @@ static int com20020_probe(struct pcmcia_device *p_dev) | |||
156 | 147 | ||
157 | p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8; | 148 | p_dev->resource[0]->flags |= IO_DATA_PATH_WIDTH_8; |
158 | p_dev->resource[0]->end = 16; | 149 | p_dev->resource[0]->end = 16; |
159 | p_dev->conf.Attributes = CONF_ENABLE_IRQ; | 150 | p_dev->config_flags |= CONF_ENABLE_IRQ; |
160 | p_dev->conf.IntType = INT_MEMORY_AND_IO; | ||
161 | 151 | ||
162 | info->dev = dev; | 152 | info->dev = dev; |
163 | p_dev->priv = info; | 153 | p_dev->priv = info; |
@@ -170,15 +160,6 @@ fail_alloc_info: | |||
170 | return -ENOMEM; | 160 | return -ENOMEM; |
171 | } /* com20020_attach */ | 161 | } /* com20020_attach */ |
172 | 162 | ||
173 | /*====================================================================== | ||
174 | |||
175 | This deletes a driver "instance". The device is de-registered | ||
176 | with Card Services. If it has been released, all local data | ||
177 | structures are freed. Otherwise, the structures will be freed | ||
178 | when the device is released. | ||
179 | |||
180 | ======================================================================*/ | ||
181 | |||
182 | static void com20020_detach(struct pcmcia_device *link) | 163 | static void com20020_detach(struct pcmcia_device *link) |
183 | { | 164 | { |
184 | struct com20020_dev_t *info = link->priv; | 165 | struct com20020_dev_t *info = link->priv; |
@@ -217,14 +198,6 @@ static void com20020_detach(struct pcmcia_device *link) | |||
217 | 198 | ||
218 | } /* com20020_detach */ | 199 | } /* com20020_detach */ |
219 | 200 | ||
220 | /*====================================================================== | ||
221 | |||
222 | com20020_config() is scheduled to run after a CARD_INSERTION event | ||
223 | is received, to configure the PCMCIA socket, and to make the | ||
224 | device available to the system. | ||
225 | |||
226 | ======================================================================*/ | ||
227 | |||
228 | static int com20020_config(struct pcmcia_device *link) | 201 | static int com20020_config(struct pcmcia_device *link) |
229 | { | 202 | { |
230 | struct arcnet_local *lp; | 203 | struct arcnet_local *lp; |
@@ -278,7 +251,7 @@ static int com20020_config(struct pcmcia_device *link) | |||
278 | 251 | ||
279 | dev->irq = link->irq; | 252 | dev->irq = link->irq; |
280 | 253 | ||
281 | ret = pcmcia_request_configuration(link, &link->conf); | 254 | ret = pcmcia_enable_device(link); |
282 | if (ret) | 255 | if (ret) |
283 | goto failed; | 256 | goto failed; |
284 | 257 | ||
@@ -312,14 +285,6 @@ failed: | |||
312 | return -ENODEV; | 285 | return -ENODEV; |
313 | } /* com20020_config */ | 286 | } /* com20020_config */ |
314 | 287 | ||
315 | /*====================================================================== | ||
316 | |||
317 | After a card is removed, com20020_release() will unregister the net | ||
318 | device, and release the PCMCIA configuration. If the device is | ||
319 | still open, this will be postponed until it is closed. | ||
320 | |||
321 | ======================================================================*/ | ||
322 | |||
323 | static void com20020_release(struct pcmcia_device *link) | 288 | static void com20020_release(struct pcmcia_device *link) |
324 | { | 289 | { |
325 | dev_dbg(&link->dev, "com20020_release\n"); | 290 | dev_dbg(&link->dev, "com20020_release\n"); |
@@ -362,9 +327,7 @@ MODULE_DEVICE_TABLE(pcmcia, com20020_ids); | |||
362 | 327 | ||
363 | static struct pcmcia_driver com20020_cs_driver = { | 328 | static struct pcmcia_driver com20020_cs_driver = { |
364 | .owner = THIS_MODULE, | 329 | .owner = THIS_MODULE, |
365 | .drv = { | 330 | .name = "com20020_cs", |
366 | .name = "com20020_cs", | ||
367 | }, | ||
368 | .probe = com20020_probe, | 331 | .probe = com20020_probe, |
369 | .remove = com20020_detach, | 332 | .remove = com20020_detach, |
370 | .id_table = com20020_ids, | 333 | .id_table = com20020_ids, |