aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJouni Malinen <jkmaline@cc.hut.fi>2005-08-14 22:08:40 -0400
committerJeff Garzik <jgarzik@pobox.com>2005-08-14 23:06:27 -0400
commitea3f1865f33bd328bf043f47492f401a42de5edb (patch)
tree03036e8bd28fd97296b1938e28cbb3723dff61a2 /drivers
parent5bee720fd7fa5ed4eade96058acd3a684da30932 (diff)
[PATCH] hostap: Remove experimental PCI bus master/DMA code
PCI version of Prism2.5/3 has undocumented DMA support for TX/RX data, but this seems to have some hardware bugs that prevent it from being used properly for TX. RX side could possibly be made to work reliably. Even though DMA support would be very useful for saving host CPU (from about 40% to 5-10% when operating at maximum throughput), it seems to be best to just remove this code finally. The implementation has always been commented out by default and has received very limited testing. The code may have already been broken number of times and I don't have much interested in trying to verify whether it works or not. Getting this out makes it easier to maintain the driver and allows some cleanups that have been partly postponed because of this experimental bus master/DMA code. Signed-off-by: Jouni Malinen <jkmaline@cc.hut.fi> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/wireless/hostap/hostap_common.h4
-rw-r--r--drivers/net/wireless/hostap/hostap_config.h31
-rw-r--r--drivers/net/wireless/hostap/hostap_hw.c211
-rw-r--r--drivers/net/wireless/hostap/hostap_ioctl.c24
-rw-r--r--drivers/net/wireless/hostap/hostap_pci.c4
-rw-r--r--drivers/net/wireless/hostap/hostap_wlan.h12
6 files changed, 13 insertions, 273 deletions
diff --git a/drivers/net/wireless/hostap/hostap_common.h b/drivers/net/wireless/hostap/hostap_common.h
index 3b79d9e95e6f..3f86263a08fd 100644
--- a/drivers/net/wireless/hostap/hostap_common.h
+++ b/drivers/net/wireless/hostap/hostap_common.h
@@ -343,8 +343,8 @@ enum {
343 PRISM2_PARAM_MONITOR_ALLOW_FCSERR = 16, 343 PRISM2_PARAM_MONITOR_ALLOW_FCSERR = 16,
344 PRISM2_PARAM_HOST_ENCRYPT = 17, 344 PRISM2_PARAM_HOST_ENCRYPT = 17,
345 PRISM2_PARAM_HOST_DECRYPT = 18, 345 PRISM2_PARAM_HOST_DECRYPT = 18,
346 PRISM2_PARAM_BUS_MASTER_THRESHOLD_RX = 19, 346 /* PRISM2_PARAM_BUS_MASTER_THRESHOLD_RX = 19, REMOVED 2005-08-14 */
347 PRISM2_PARAM_BUS_MASTER_THRESHOLD_TX = 20, 347 /* PRISM2_PARAM_BUS_MASTER_THRESHOLD_TX = 20, REMOVED 2005-08-14 */
348 PRISM2_PARAM_HOST_ROAMING = 21, 348 PRISM2_PARAM_HOST_ROAMING = 21,
349 PRISM2_PARAM_BCRX_STA_KEY = 22, 349 PRISM2_PARAM_BCRX_STA_KEY = 22,
350 PRISM2_PARAM_IEEE_802_1X = 23, 350 PRISM2_PARAM_IEEE_802_1X = 23,
diff --git a/drivers/net/wireless/hostap/hostap_config.h b/drivers/net/wireless/hostap/hostap_config.h
index 0b526febd1a8..174068bffd82 100644
--- a/drivers/net/wireless/hostap/hostap_config.h
+++ b/drivers/net/wireless/hostap/hostap_config.h
@@ -13,37 +13,6 @@
13/* Maximum number of events handler per one interrupt */ 13/* Maximum number of events handler per one interrupt */
14#define PRISM2_MAX_INTERRUPT_EVENTS 20 14#define PRISM2_MAX_INTERRUPT_EVENTS 20
15 15
16/* Use PCI bus master to copy data to/from BAP (only available for
17 * hostap_pci.o).
18 *
19 * Note! This is extremely experimental. PCI bus master is not supported by
20 * Intersil and it seems to have some problems at least on TX path (see below).
21 * The driver code for implementing bus master support is based on guessing
22 * and experimenting suitable control bits and these might not be correct.
23 * This code is included because using bus master makes a huge difference in
24 * host CPU load (something like 40% host CPU usage to 5-10% when sending or
25 * receiving at maximum throughput).
26 *
27 * Note2! Station firmware version 1.3.5 and primary firmware version 1.0.7
28 * have some fixes for PCI corruption and these (or newer) versions are
29 * recommended especially when using bus mastering.
30 *
31 * NOTE: PCI bus mastering code has not been updated for long time and it is
32 * not likely to compile and it will _not_ work as is. Only enable this if you
33 * are prepared to first fix the implementation..
34 */
35/* #define PRISM2_BUS_MASTER */
36
37#ifdef PRISM2_BUS_MASTER
38
39/* PCI bus master implementation seems to be broken in current
40 * hardware/firmware versions. Enable this to use enable command to fix
41 * something before starting bus master operation on TX path. This will add
42 * some latency and an extra interrupt to each TX packet. */
43#define PRISM2_ENABLE_BEFORE_TX_BUS_MASTER
44
45#endif /* PRISM2_BUS_MASTER */
46
47/* Include code for downloading firmware images into volatile RAM. */ 16/* Include code for downloading firmware images into volatile RAM. */
48#define PRISM2_DOWNLOAD_SUPPORT 17#define PRISM2_DOWNLOAD_SUPPORT
49 18
diff --git a/drivers/net/wireless/hostap/hostap_hw.c b/drivers/net/wireless/hostap/hostap_hw.c
index dc31f5351b36..30c215106714 100644
--- a/drivers/net/wireless/hostap/hostap_hw.c
+++ b/drivers/net/wireless/hostap/hostap_hw.c
@@ -83,18 +83,6 @@ static int dtim_period[MAX_PARM_DEVICES] = { 1, DEF_INTS };
83module_param_array(dtim_period, int, NULL, 0444); 83module_param_array(dtim_period, int, NULL, 0444);
84MODULE_PARM_DESC(dtim_period, "DTIM period"); 84MODULE_PARM_DESC(dtim_period, "DTIM period");
85 85
86#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
87static int bus_master_threshold_rx[MAX_PARM_DEVICES] = { 100, DEF_INTS };
88module_param_array(bus_master_threshold_rx, int, NULL, 0444);
89MODULE_PARM_DESC(bus_master_threshold_rx, "Packet length threshold for using "
90 "PCI bus master on RX");
91
92static int bus_master_threshold_tx[MAX_PARM_DEVICES] = { 100, DEF_INTS };
93module_param_array(bus_master_threshold_tx, int, NULL, 0444);
94MODULE_PARM_DESC(bus_master_threshold_tx, "Packet length threshold for using "
95 "PCI bus master on TX");
96#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
97
98static char dev_template[16] = "wlan%d"; 86static char dev_template[16] = "wlan%d";
99module_param_string(dev_template, dev_template, sizeof(dev_template), 0444); 87module_param_string(dev_template, dev_template, sizeof(dev_template), 0444);
100MODULE_PARM_DESC(dev_template, "Prefix for network device name (default: " 88MODULE_PARM_DESC(dev_template, "Prefix for network device name (default: "
@@ -107,12 +95,6 @@ MODULE_PARM_DESC(dev_template, "Prefix for network device name (default: "
107#define EXTRA_EVENTS_WTERR HFA384X_EV_WTERR 95#define EXTRA_EVENTS_WTERR HFA384X_EV_WTERR
108#endif 96#endif
109 97
110#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
111#define EXTRA_EVENTS_BUS_MASTER (HFA384X_EV_PCI_M0 | HFA384X_EV_PCI_M1)
112#else
113#define EXTRA_EVENTS_BUS_MASTER 0
114#endif
115
116/* Events that will be using BAP0 */ 98/* Events that will be using BAP0 */
117#define HFA384X_BAP0_EVENTS \ 99#define HFA384X_BAP0_EVENTS \
118 (HFA384X_EV_TXEXC | HFA384X_EV_RX | HFA384X_EV_INFO | HFA384X_EV_TX) 100 (HFA384X_EV_TXEXC | HFA384X_EV_RX | HFA384X_EV_INFO | HFA384X_EV_TX)
@@ -121,7 +103,7 @@ MODULE_PARM_DESC(dev_template, "Prefix for network device name (default: "
121#define HFA384X_EVENT_MASK \ 103#define HFA384X_EVENT_MASK \
122 (HFA384X_BAP0_EVENTS | HFA384X_EV_ALLOC | HFA384X_EV_INFDROP | \ 104 (HFA384X_BAP0_EVENTS | HFA384X_EV_ALLOC | HFA384X_EV_INFDROP | \
123 HFA384X_EV_CMD | HFA384X_EV_TICK | \ 105 HFA384X_EV_CMD | HFA384X_EV_TICK | \
124 EXTRA_EVENTS_WTERR | EXTRA_EVENTS_BUS_MASTER) 106 EXTRA_EVENTS_WTERR)
125 107
126/* Default TX control flags: use 802.11 headers and request interrupt for 108/* Default TX control flags: use 802.11 headers and request interrupt for
127 * failed transmits. Frames that request ACK callback, will add 109 * failed transmits. Frames that request ACK callback, will add
@@ -1827,34 +1809,6 @@ static int prism2_transmit(struct net_device *dev, int idx)
1827} 1809}
1828 1810
1829 1811
1830#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
1831/* Called only from hardware IRQ */
1832static void prism2_tx_cb(struct net_device *dev, void *context,
1833 u16 resp0, u16 res)
1834{
1835 struct hostap_interface *iface;
1836 local_info_t *local;
1837 unsigned long addr;
1838 int buf_len = (int) context;
1839
1840 iface = netdev_priv(dev);
1841 local = iface->local;
1842
1843 if (res) {
1844 printk(KERN_DEBUG "%s: prism2_tx_cb - res=0x%02x\n",
1845 dev->name, res);
1846 return;
1847 }
1848
1849 addr = virt_to_phys(local->bus_m0_buf);
1850 HFA384X_OUTW((addr & 0xffff0000) >> 16, HFA384X_PCI_M0_ADDRH_OFF);
1851 HFA384X_OUTW(addr & 0x0000ffff, HFA384X_PCI_M0_ADDRL_OFF);
1852 HFA384X_OUTW(buf_len / 2, HFA384X_PCI_M0_LEN_OFF);
1853 HFA384X_OUTW(HFA384X_PCI_CTL_TO_BAP, HFA384X_PCI_M0_CTL_OFF);
1854}
1855#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
1856
1857
1858/* Send IEEE 802.11 frame (convert the header into Prism2 TX descriptor and 1812/* Send IEEE 802.11 frame (convert the header into Prism2 TX descriptor and
1859 * send the payload with this descriptor) */ 1813 * send the payload with this descriptor) */
1860/* Called only from software IRQ */ 1814/* Called only from software IRQ */
@@ -1920,53 +1874,6 @@ static int prism2_tx_80211(struct sk_buff *skb, struct net_device *dev)
1920 spin_lock(&local->baplock); 1874 spin_lock(&local->baplock);
1921 res = hfa384x_setup_bap(dev, BAP0, local->txfid[idx], 0); 1875 res = hfa384x_setup_bap(dev, BAP0, local->txfid[idx], 0);
1922 1876
1923#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
1924 if (!res && skb->len >= local->bus_master_threshold_tx) {
1925 u8 *pos;
1926 int buf_len;
1927
1928 local->bus_m0_tx_idx = idx;
1929
1930 /* FIX: BAP0 should be locked during bus master transfer, but
1931 * baplock with BH's disabled is not OK for this; netif queue
1932 * stopping is not enough since BAP0 is used also for RID
1933 * read/write */
1934
1935 /* stop the queue for the time that bus mastering on BAP0 is
1936 * in use */
1937 netif_stop_queue(dev);
1938
1939 spin_unlock(&local->baplock);
1940
1941 /* Copy frame data to bus_m0_buf */
1942 pos = local->bus_m0_buf;
1943 memcpy(pos, &txdesc, sizeof(txdesc));
1944 pos += sizeof(txdesc);
1945 memcpy(pos, skb->data + hdr_len, skb->len - hdr_len);
1946 pos += skb->len - hdr_len;
1947 buf_len = pos - local->bus_m0_buf;
1948 if (buf_len & 1)
1949 buf_len++;
1950
1951#ifdef PRISM2_ENABLE_BEFORE_TX_BUS_MASTER
1952 /* Any RX packet seems to break something with TX bus
1953 * mastering; enable command is enough to fix this.. */
1954 if (hfa384x_cmd_callback(dev, HFA384X_CMDCODE_ENABLE, 0,
1955 prism2_tx_cb, (long) buf_len)) {
1956 printk(KERN_DEBUG "%s: TX: enable port0 failed\n",
1957 dev->name);
1958 }
1959#else /* PRISM2_ENABLE_BEFORE_TX_BUS_MASTER */
1960 prism2_tx_cb(dev, (void *) buf_len, 0, 0);
1961#endif /* PRISM2_ENABLE_BEFORE_TX_BUS_MASTER */
1962
1963 /* Bus master transfer will be started from command completion
1964 * event handler and TX handling will be finished by calling
1965 * prism2_transmit() from bus master event handler */
1966 goto tx_stats;
1967 }
1968#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
1969
1970 if (!res) 1877 if (!res)
1971 res = hfa384x_to_bap(dev, BAP0, &txdesc, sizeof(txdesc)); 1878 res = hfa384x_to_bap(dev, BAP0, &txdesc, sizeof(txdesc));
1972 if (!res) 1879 if (!res)
@@ -2107,50 +2014,18 @@ static void prism2_rx(local_info_t *local)
2107 skb->dev = dev; 2014 skb->dev = dev;
2108 memcpy(skb_put(skb, hdr_len), &rxdesc, hdr_len); 2015 memcpy(skb_put(skb, hdr_len), &rxdesc, hdr_len);
2109 2016
2110#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER) 2017 if (len > 0)
2111 if (len >= local->bus_master_threshold_rx) { 2018 res = hfa384x_from_bap(dev, BAP0, skb_put(skb, len), len);
2112 unsigned long addr; 2019 spin_unlock(&local->baplock);
2113 2020 if (res) {
2114 hfa384x_events_no_bap1(dev); 2021 printk(KERN_DEBUG "%s: RX failed to read "
2115 2022 "frame data\n", dev->name);
2116 local->rx_skb = skb; 2023 goto rx_dropped;
2117 /* Internal BAP0 offset points to the byte following rxdesc;
2118 * copy rest of the data using bus master */
2119 addr = virt_to_phys(skb_put(skb, len));
2120 HFA384X_OUTW((addr & 0xffff0000) >> 16,
2121 HFA384X_PCI_M0_ADDRH_OFF);
2122 HFA384X_OUTW(addr & 0x0000ffff, HFA384X_PCI_M0_ADDRL_OFF);
2123 if (len & 1)
2124 len++;
2125 HFA384X_OUTW(len / 2, HFA384X_PCI_M0_LEN_OFF);
2126 HFA384X_OUTW(HFA384X_PCI_CTL_FROM_BAP, HFA384X_PCI_M0_CTL_OFF);
2127
2128 /* pci_bus_m1 event will be generated when data transfer is
2129 * complete and the frame will then be added to rx_list and
2130 * rx_tasklet is scheduled */
2131 rx_pending = 1;
2132
2133 /* Have to release baplock before returning, although BAP0
2134 * should really not be used before DMA transfer has been
2135 * completed. */
2136 spin_unlock(&local->baplock);
2137 } else
2138#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
2139 {
2140 if (len > 0)
2141 res = hfa384x_from_bap(dev, BAP0, skb_put(skb, len),
2142 len);
2143 spin_unlock(&local->baplock);
2144 if (res) {
2145 printk(KERN_DEBUG "%s: RX failed to read "
2146 "frame data\n", dev->name);
2147 goto rx_dropped;
2148 }
2149
2150 skb_queue_tail(&local->rx_list, skb);
2151 tasklet_schedule(&local->rx_tasklet);
2152 } 2024 }
2153 2025
2026 skb_queue_tail(&local->rx_list, skb);
2027 tasklet_schedule(&local->rx_tasklet);
2028
2154 rx_exit: 2029 rx_exit:
2155 prism2_callback(local, PRISM2_CALLBACK_RX_END); 2030 prism2_callback(local, PRISM2_CALLBACK_RX_END);
2156 if (!rx_pending) { 2031 if (!rx_pending) {
@@ -2654,36 +2529,6 @@ static void hostap_bap_tasklet(unsigned long data)
2654} 2529}
2655 2530
2656 2531
2657#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
2658/* Called only from hardware IRQ */
2659static void prism2_bus_master_ev(struct net_device *dev, int bap)
2660{
2661 struct hostap_interface *iface;
2662 local_info_t *local;
2663
2664 iface = netdev_priv(dev);
2665 local = iface->local;
2666
2667 if (bap == BAP1) {
2668 /* FIX: frame payload was DMA'd to skb->data; might need to
2669 * invalidate data cache for that memory area */
2670 skb_queue_tail(&local->rx_list, local->rx_skb);
2671 tasklet_schedule(&local->rx_tasklet);
2672 HFA384X_OUTW(HFA384X_EV_RX, HFA384X_EVACK_OFF);
2673 } else {
2674 if (prism2_transmit(dev, local->bus_m0_tx_idx)) {
2675 printk(KERN_DEBUG "%s: prism2_transmit() failed "
2676 "when called from bus master event\n",
2677 dev->name);
2678 local->intransmitfid[local->bus_m0_tx_idx] =
2679 PRISM2_TXFID_EMPTY;
2680 schedule_work(&local->reset_queue);
2681 }
2682 }
2683}
2684#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
2685
2686
2687/* Called only from hardware IRQ */ 2532/* Called only from hardware IRQ */
2688static void prism2_infdrop(struct net_device *dev) 2533static void prism2_infdrop(struct net_device *dev)
2689{ 2534{
@@ -2852,21 +2697,6 @@ static irqreturn_t prism2_interrupt(int irq, void *dev_id, struct pt_regs *regs)
2852 HFA384X_OUTW(HFA384X_EV_TICK, HFA384X_EVACK_OFF); 2697 HFA384X_OUTW(HFA384X_EV_TICK, HFA384X_EVACK_OFF);
2853 } 2698 }
2854 2699
2855#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
2856 if (ev & HFA384X_EV_PCI_M0) {
2857 prism2_bus_master_ev(dev, BAP0);
2858 HFA384X_OUTW(HFA384X_EV_PCI_M0, HFA384X_EVACK_OFF);
2859 }
2860
2861 if (ev & HFA384X_EV_PCI_M1) {
2862 /* previous RX has been copied can be ACKed now */
2863 HFA384X_OUTW(HFA384X_EV_RX, HFA384X_EVACK_OFF);
2864
2865 prism2_bus_master_ev(dev, BAP1);
2866 HFA384X_OUTW(HFA384X_EV_PCI_M1, HFA384X_EVACK_OFF);
2867 }
2868#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
2869
2870 if (ev & HFA384X_EV_ALLOC) { 2700 if (ev & HFA384X_EV_ALLOC) {
2871 prism2_alloc_ev(dev); 2701 prism2_alloc_ev(dev);
2872 HFA384X_OUTW(HFA384X_EV_ALLOC, HFA384X_EVACK_OFF); 2702 HFA384X_OUTW(HFA384X_EV_ALLOC, HFA384X_EVACK_OFF);
@@ -3309,13 +3139,6 @@ prism2_init_local_data(struct prism2_helper_functions *funcs, int card_idx,
3309 local->io_debug_enabled = 1; 3139 local->io_debug_enabled = 1;
3310#endif /* PRISM2_IO_DEBUG */ 3140#endif /* PRISM2_IO_DEBUG */
3311 3141
3312#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
3313 local->bus_m0_buf = (u8 *) kmalloc(sizeof(struct hfa384x_tx_frame) +
3314 PRISM2_DATA_MAXLEN, GFP_DMA);
3315 if (local->bus_m0_buf == NULL)
3316 goto fail;
3317#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
3318
3319 local->func = funcs; 3142 local->func = funcs;
3320 local->func->cmd = hfa384x_cmd; 3143 local->func->cmd = hfa384x_cmd;
3321 local->func->read_regs = hfa384x_read_regs; 3144 local->func->read_regs = hfa384x_read_regs;
@@ -3376,12 +3199,6 @@ prism2_init_local_data(struct prism2_helper_functions *funcs, int card_idx,
3376 local->auth_algs = PRISM2_AUTH_OPEN | PRISM2_AUTH_SHARED_KEY; 3199 local->auth_algs = PRISM2_AUTH_OPEN | PRISM2_AUTH_SHARED_KEY;
3377 local->sram_type = -1; 3200 local->sram_type = -1;
3378 local->scan_channel_mask = 0xffff; 3201 local->scan_channel_mask = 0xffff;
3379#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
3380 local->bus_master_threshold_rx = GET_INT_PARM(bus_master_threshold_rx,
3381 card_idx);
3382 local->bus_master_threshold_tx = GET_INT_PARM(bus_master_threshold_tx,
3383 card_idx);
3384#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
3385 3202
3386 /* Initialize task queue structures */ 3203 /* Initialize task queue structures */
3387 INIT_WORK(&local->reset_queue, handle_reset_queue, local); 3204 INIT_WORK(&local->reset_queue, handle_reset_queue, local);
@@ -3462,9 +3279,6 @@ while (0)
3462 return dev; 3279 return dev;
3463 3280
3464 fail: 3281 fail:
3465#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
3466 kfree(local->bus_m0_buf);
3467#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
3468 free_netdev(dev); 3282 free_netdev(dev);
3469 return NULL; 3283 return NULL;
3470} 3284}
@@ -3586,9 +3400,6 @@ static void prism2_free_local_data(struct net_device *dev)
3586 kfree(bss); 3400 kfree(bss);
3587 } 3401 }
3588 3402
3589#if defined(PRISM2_PCI) && defined(PRISM2_BUS_MASTER)
3590 kfree(local->bus_m0_buf);
3591#endif /* PRISM2_PCI and PRISM2_BUS_MASTER */
3592 kfree(local->pda); 3403 kfree(local->pda);
3593 kfree(local->last_scan_results); 3404 kfree(local->last_scan_results);
3594 kfree(local->generic_elem); 3405 kfree(local->generic_elem);
diff --git a/drivers/net/wireless/hostap/hostap_ioctl.c b/drivers/net/wireless/hostap/hostap_ioctl.c
index cfe127a10850..267f68b4d7fd 100644
--- a/drivers/net/wireless/hostap/hostap_ioctl.c
+++ b/drivers/net/wireless/hostap/hostap_ioctl.c
@@ -2239,14 +2239,6 @@ static const struct iw_priv_args prism2_priv[] = {
2239 IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "host_decrypt" }, 2239 IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "host_decrypt" },
2240 { PRISM2_PARAM_HOST_DECRYPT, 2240 { PRISM2_PARAM_HOST_DECRYPT,
2241 0, IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, "gethost_decrypt" }, 2241 0, IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, "gethost_decrypt" },
2242 { PRISM2_PARAM_BUS_MASTER_THRESHOLD_RX,
2243 IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "busmaster_rx" },
2244 { PRISM2_PARAM_BUS_MASTER_THRESHOLD_RX,
2245 0, IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, "getbusmaster_rx" },
2246 { PRISM2_PARAM_BUS_MASTER_THRESHOLD_TX,
2247 IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "busmaster_tx" },
2248 { PRISM2_PARAM_BUS_MASTER_THRESHOLD_TX,
2249 0, IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, "getbusmaster_tx" },
2250#ifndef PRISM2_NO_STATION_MODES 2242#ifndef PRISM2_NO_STATION_MODES
2251 { PRISM2_PARAM_HOST_ROAMING, 2243 { PRISM2_PARAM_HOST_ROAMING,
2252 IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "host_roaming" }, 2244 IW_PRIV_TYPE_INT | IW_PRIV_SIZE_FIXED | 1, 0, "host_roaming" },
@@ -2495,14 +2487,6 @@ static int prism2_ioctl_priv_prism2_param(struct net_device *dev,
2495 ret = -EINVAL; 2487 ret = -EINVAL;
2496 break; 2488 break;
2497 2489
2498 case PRISM2_PARAM_BUS_MASTER_THRESHOLD_RX:
2499 local->bus_master_threshold_rx = value;
2500 break;
2501
2502 case PRISM2_PARAM_BUS_MASTER_THRESHOLD_TX:
2503 local->bus_master_threshold_tx = value;
2504 break;
2505
2506#ifndef PRISM2_NO_STATION_MODES 2490#ifndef PRISM2_NO_STATION_MODES
2507 case PRISM2_PARAM_HOST_ROAMING: 2491 case PRISM2_PARAM_HOST_ROAMING:
2508 if (value < 0 || value > 2) { 2492 if (value < 0 || value > 2) {
@@ -2799,14 +2783,6 @@ static int prism2_ioctl_priv_get_prism2_param(struct net_device *dev,
2799 *param = local->host_decrypt; 2783 *param = local->host_decrypt;
2800 break; 2784 break;
2801 2785
2802 case PRISM2_PARAM_BUS_MASTER_THRESHOLD_RX:
2803 *param = local->bus_master_threshold_rx;
2804 break;
2805
2806 case PRISM2_PARAM_BUS_MASTER_THRESHOLD_TX:
2807 *param = local->bus_master_threshold_tx;
2808 break;
2809
2810 case PRISM2_PARAM_HOST_ROAMING: 2786 case PRISM2_PARAM_HOST_ROAMING:
2811 *param = local->host_roaming; 2787 *param = local->host_roaming;
2812 break; 2788 break;
diff --git a/drivers/net/wireless/hostap/hostap_pci.c b/drivers/net/wireless/hostap/hostap_pci.c
index 786c146f533e..79074b3d10d7 100644
--- a/drivers/net/wireless/hostap/hostap_pci.c
+++ b/drivers/net/wireless/hostap/hostap_pci.c
@@ -305,10 +305,6 @@ static int prism2_pci_probe(struct pci_dev *pdev,
305 goto fail; 305 goto fail;
306 } 306 }
307 307
308#ifdef PRISM2_BUS_MASTER
309 pci_set_master(pdev);
310#endif /* PRISM2_BUS_MASTER */
311
312 dev = prism2_init_local_data(&prism2_pci_funcs, cards_found, 308 dev = prism2_init_local_data(&prism2_pci_funcs, cards_found,
313 &pdev->dev); 309 &pdev->dev);
314 if (dev == NULL) 310 if (dev == NULL)
diff --git a/drivers/net/wireless/hostap/hostap_wlan.h b/drivers/net/wireless/hostap/hostap_wlan.h
index 6f5bea8a5c23..56416b43e414 100644
--- a/drivers/net/wireless/hostap/hostap_wlan.h
+++ b/drivers/net/wireless/hostap/hostap_wlan.h
@@ -787,10 +787,6 @@ struct local_info {
787 787
788 struct prism2_helper_functions *func; 788 struct prism2_helper_functions *func;
789 789
790 int bus_master_threshold_tx;
791 int bus_master_threshold_rx;
792 u8 *bus_m1_buf;
793
794 u8 *pda; 790 u8 *pda;
795 int fw_ap; 791 int fw_ap;
796#define PRISM2_FW_VER(major, minor, variant) \ 792#define PRISM2_FW_VER(major, minor, variant) \
@@ -897,14 +893,6 @@ struct local_info {
897 893
898#ifdef PRISM2_PCI 894#ifdef PRISM2_PCI
899 void __iomem *mem_start; 895 void __iomem *mem_start;
900#ifdef PRISM2_BUS_MASTER
901 /* bus master for BAP0 (TX) */
902 int bus_m0_tx_idx;
903 u8 *bus_m0_buf;
904
905 /* bus master for BAP1 (RX) */
906 struct sk_buff *rx_skb;
907#endif /* PRISM2_BUS_MASTER */
908#endif /* PRISM2_PCI */ 896#endif /* PRISM2_PCI */
909 897
910 /* NOTE! Do not add common entries here after hardware version 898 /* NOTE! Do not add common entries here after hardware version