aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/pcmcia/xirc2ps_cs.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/pcmcia/xirc2ps_cs.c')
-rw-r--r--drivers/net/pcmcia/xirc2ps_cs.c53
1 files changed, 0 insertions, 53 deletions
diff --git a/drivers/net/pcmcia/xirc2ps_cs.c b/drivers/net/pcmcia/xirc2ps_cs.c
index 18cdc84a84bf..1fece617c069 100644
--- a/drivers/net/pcmcia/xirc2ps_cs.c
+++ b/drivers/net/pcmcia/xirc2ps_cs.c
@@ -266,33 +266,11 @@ static unsigned mii_rd(unsigned int ioaddr, u_char phyaddr, u_char phyreg);
266static void mii_wr(unsigned int ioaddr, u_char phyaddr, u_char phyreg, 266static void mii_wr(unsigned int ioaddr, u_char phyaddr, u_char phyreg,
267 unsigned data, int len); 267 unsigned data, int len);
268 268
269/*
270 * The event() function is this driver's Card Services event handler.
271 * It will be called by Card Services when an appropriate card status
272 * event is received. The config() and release() entry points are
273 * used to configure or release a socket, in response to card insertion
274 * and ejection events. They are invoked from the event handler.
275 */
276
277static int has_ce2_string(struct pcmcia_device * link); 269static int has_ce2_string(struct pcmcia_device * link);
278static int xirc2ps_config(struct pcmcia_device * link); 270static int xirc2ps_config(struct pcmcia_device * link);
279static void xirc2ps_release(struct pcmcia_device * link); 271static void xirc2ps_release(struct pcmcia_device * link);
280
281/****************
282 * The attach() and detach() entry points are used to create and destroy
283 * "instances" of the driver, where each instance represents everything
284 * needed to manage one actual PCMCIA card.
285 */
286
287static void xirc2ps_detach(struct pcmcia_device *p_dev); 272static void xirc2ps_detach(struct pcmcia_device *p_dev);
288 273
289/****************
290 * You'll also need to prototype all the functions that will actually
291 * be used to talk to your device. See 'pcmem_cs' for a good example
292 * of a fully self-sufficient driver; the other drivers rely more or
293 * less on other parts of the kernel.
294 */
295
296static irqreturn_t xirc2ps_interrupt(int irq, void *dev_id); 274static irqreturn_t xirc2ps_interrupt(int irq, void *dev_id);
297 275
298typedef struct local_info_t { 276typedef struct local_info_t {
@@ -500,16 +478,6 @@ static const struct net_device_ops netdev_ops = {
500 .ndo_validate_addr = eth_validate_addr, 478 .ndo_validate_addr = eth_validate_addr,
501}; 479};
502 480
503/****************
504 * xirc2ps_attach() creates an "instance" of the driver, allocating
505 * local data structures for one device. The device is registered
506 * with Card Services.
507 *
508 * The dev_link structure is initialized, but we don't actually
509 * configure the card at this point -- we wait until we receive a
510 * card insertion event.
511 */
512
513static int 481static int
514xirc2ps_probe(struct pcmcia_device *link) 482xirc2ps_probe(struct pcmcia_device *link)
515{ 483{
@@ -539,13 +507,6 @@ xirc2ps_probe(struct pcmcia_device *link)
539 return xirc2ps_config(link); 507 return xirc2ps_config(link);
540} /* xirc2ps_attach */ 508} /* xirc2ps_attach */
541 509
542/****************
543 * This deletes a driver "instance". The device is de-registered
544 * with Card Services. If it has been released, all local data
545 * structures are freed. Otherwise, the structures will be freed
546 * when the device is released.
547 */
548
549static void 510static void
550xirc2ps_detach(struct pcmcia_device *link) 511xirc2ps_detach(struct pcmcia_device *link)
551{ 512{
@@ -733,11 +694,6 @@ static int pcmcia_get_mac_ce(struct pcmcia_device *p_dev,
733}; 694};
734 695
735 696
736/****************
737 * xirc2ps_config() is scheduled to run after a CARD_INSERTION event
738 * is received, to configure the PCMCIA socket, and to make the
739 * ethernet device available to the system.
740 */
741static int 697static int
742xirc2ps_config(struct pcmcia_device * link) 698xirc2ps_config(struct pcmcia_device * link)
743{ 699{
@@ -861,10 +817,6 @@ xirc2ps_config(struct pcmcia_device * link)
861 if ((err=pcmcia_request_irq(link, xirc2ps_interrupt))) 817 if ((err=pcmcia_request_irq(link, xirc2ps_interrupt)))
862 goto config_error; 818 goto config_error;
863 819
864 /****************
865 * This actually configures the PCMCIA socket -- setting up
866 * the I/O windows and the interrupt mapping.
867 */
868 link->config_flags |= CONF_ENABLE_IRQ; 820 link->config_flags |= CONF_ENABLE_IRQ;
869 if (do_sound) 821 if (do_sound)
870 link->config_flags |= CONF_ENABLE_SPKR; 822 link->config_flags |= CONF_ENABLE_SPKR;
@@ -980,11 +932,6 @@ xirc2ps_config(struct pcmcia_device * link)
980 return -ENODEV; 932 return -ENODEV;
981} /* xirc2ps_config */ 933} /* xirc2ps_config */
982 934
983/****************
984 * After a card is removed, xirc2ps_release() will unregister the net
985 * device, and release the PCMCIA configuration. If the device is
986 * still open, this will be postponed until it is closed.
987 */
988static void 935static void
989xirc2ps_release(struct pcmcia_device *link) 936xirc2ps_release(struct pcmcia_device *link)
990{ 937{