diff options
Diffstat (limited to 'drivers/net/wireless/wl3501_cs.c')
-rw-r--r-- | drivers/net/wireless/wl3501_cs.c | 47 |
1 files changed, 4 insertions, 43 deletions
diff --git a/drivers/net/wireless/wl3501_cs.c b/drivers/net/wireless/wl3501_cs.c index 420e9e986a18..ee82df62e646 100644 --- a/drivers/net/wireless/wl3501_cs.c +++ b/drivers/net/wireless/wl3501_cs.c | |||
@@ -47,7 +47,6 @@ | |||
47 | 47 | ||
48 | #include <net/iw_handler.h> | 48 | #include <net/iw_handler.h> |
49 | 49 | ||
50 | #include <pcmcia/cs.h> | ||
51 | #include <pcmcia/cistpl.h> | 50 | #include <pcmcia/cistpl.h> |
52 | #include <pcmcia/cisreg.h> | 51 | #include <pcmcia/cisreg.h> |
53 | #include <pcmcia/ds.h> | 52 | #include <pcmcia/ds.h> |
@@ -77,13 +76,6 @@ | |||
77 | #define WL3501_RESUME 0 | 76 | #define WL3501_RESUME 0 |
78 | #define WL3501_SUSPEND 1 | 77 | #define WL3501_SUSPEND 1 |
79 | 78 | ||
80 | /* | ||
81 | * The event() function is this driver's Card Services event handler. It will | ||
82 | * be called by Card Services when an appropriate card status event is | ||
83 | * received. The config() and release() entry points are used to configure or | ||
84 | * release a socket, in response to card insertion and ejection events. They | ||
85 | * are invoked from the wl24 event handler. | ||
86 | */ | ||
87 | static int wl3501_config(struct pcmcia_device *link); | 79 | static int wl3501_config(struct pcmcia_device *link); |
88 | static void wl3501_release(struct pcmcia_device *link); | 80 | static void wl3501_release(struct pcmcia_device *link); |
89 | 81 | ||
@@ -1859,15 +1851,6 @@ static const struct net_device_ops wl3501_netdev_ops = { | |||
1859 | .ndo_validate_addr = eth_validate_addr, | 1851 | .ndo_validate_addr = eth_validate_addr, |
1860 | }; | 1852 | }; |
1861 | 1853 | ||
1862 | /** | ||
1863 | * wl3501_attach - creates an "instance" of the driver | ||
1864 | * | ||
1865 | * Creates an "instance" of the driver, allocating local data structures for | ||
1866 | * one device. The device is registered with Card Services. | ||
1867 | * | ||
1868 | * The dev_link structure is initialized, but we don't actually configure the | ||
1869 | * card at this point -- we wait until we receive a card insertion event. | ||
1870 | */ | ||
1871 | static int wl3501_probe(struct pcmcia_device *p_dev) | 1854 | static int wl3501_probe(struct pcmcia_device *p_dev) |
1872 | { | 1855 | { |
1873 | struct net_device *dev; | 1856 | struct net_device *dev; |
@@ -1878,9 +1861,8 @@ static int wl3501_probe(struct pcmcia_device *p_dev) | |||
1878 | p_dev->resource[0]->flags = IO_DATA_PATH_WIDTH_8; | 1861 | p_dev->resource[0]->flags = IO_DATA_PATH_WIDTH_8; |
1879 | 1862 | ||
1880 | /* General socket configuration */ | 1863 | /* General socket configuration */ |
1881 | p_dev->conf.Attributes = CONF_ENABLE_IRQ; | 1864 | p_dev->config_flags = CONF_ENABLE_IRQ; |
1882 | p_dev->conf.IntType = INT_MEMORY_AND_IO; | 1865 | p_dev->config_index = 1; |
1883 | p_dev->conf.ConfigIndex = 1; | ||
1884 | 1866 | ||
1885 | dev = alloc_etherdev(sizeof(struct wl3501_card)); | 1867 | dev = alloc_etherdev(sizeof(struct wl3501_card)); |
1886 | if (!dev) | 1868 | if (!dev) |
@@ -1903,14 +1885,6 @@ out_link: | |||
1903 | return -ENOMEM; | 1885 | return -ENOMEM; |
1904 | } | 1886 | } |
1905 | 1887 | ||
1906 | /** | ||
1907 | * wl3501_config - configure the PCMCIA socket and make eth device available | ||
1908 | * @link - FILL_IN | ||
1909 | * | ||
1910 | * wl3501_config() is scheduled to run after a CARD_INSERTION event is | ||
1911 | * received, to configure the PCMCIA socket, and to make the ethernet device | ||
1912 | * available to the system. | ||
1913 | */ | ||
1914 | static int wl3501_config(struct pcmcia_device *link) | 1888 | static int wl3501_config(struct pcmcia_device *link) |
1915 | { | 1889 | { |
1916 | struct net_device *dev = link->priv; | 1890 | struct net_device *dev = link->priv; |
@@ -1941,10 +1915,7 @@ static int wl3501_config(struct pcmcia_device *link) | |||
1941 | if (ret) | 1915 | if (ret) |
1942 | goto failed; | 1916 | goto failed; |
1943 | 1917 | ||
1944 | /* This actually configures the PCMCIA socket -- setting up the I/O | 1918 | ret = pcmcia_enable_device(link); |
1945 | * windows and the interrupt mapping. */ | ||
1946 | |||
1947 | ret = pcmcia_request_configuration(link, &link->conf); | ||
1948 | if (ret) | 1919 | if (ret) |
1949 | goto failed; | 1920 | goto failed; |
1950 | 1921 | ||
@@ -1999,14 +1970,6 @@ failed: | |||
1999 | return -ENODEV; | 1970 | return -ENODEV; |
2000 | } | 1971 | } |
2001 | 1972 | ||
2002 | /** | ||
2003 | * wl3501_release - unregister the net, release PCMCIA configuration | ||
2004 | * @arg - link | ||
2005 | * | ||
2006 | * After a card is removed, wl3501_release() will unregister the net device, | ||
2007 | * and release the PCMCIA configuration. If the device is still open, this | ||
2008 | * will be postponed until it is closed. | ||
2009 | */ | ||
2010 | static void wl3501_release(struct pcmcia_device *link) | 1973 | static void wl3501_release(struct pcmcia_device *link) |
2011 | { | 1974 | { |
2012 | pcmcia_disable_device(link); | 1975 | pcmcia_disable_device(link); |
@@ -2045,9 +2008,7 @@ MODULE_DEVICE_TABLE(pcmcia, wl3501_ids); | |||
2045 | 2008 | ||
2046 | static struct pcmcia_driver wl3501_driver = { | 2009 | static struct pcmcia_driver wl3501_driver = { |
2047 | .owner = THIS_MODULE, | 2010 | .owner = THIS_MODULE, |
2048 | .drv = { | 2011 | .name = "wl3501_cs", |
2049 | .name = "wl3501_cs", | ||
2050 | }, | ||
2051 | .probe = wl3501_probe, | 2012 | .probe = wl3501_probe, |
2052 | .remove = wl3501_detach, | 2013 | .remove = wl3501_detach, |
2053 | .id_table = wl3501_ids, | 2014 | .id_table = wl3501_ids, |