d80211: pull request
Subsystems (4)
cover d80211: pull request
Please pull fromgit://git.kernel.org/pub/scm/linux/kernel/git/jbenc/dscape.git up to obtain following patches:
David Kimdon:
d80211: allow for hardware crypto of default keys
d80211: set default_wep_only dynamically
d80211: fix potential interface name overflow
d80211: fix potential invalid array index returning key information
d80211: remove unused references to sub interface data
d80211: fix invalid check for sub interface type AP
d80211: do not pass an invalid key index to set_key()
Jiri Benc:
Merge branch 'from-john'
Michael Buesch:
d80211: Fix errorcode in ieee80211_update_hw
Michael Wu:
d80211: remove pkt_type/pkt_probe_resp
d80211: move 802.11 defines to linux/ieee80211.h
d80211: merge d80211_shared.h into d80211.h
d80211: merge d80211_mgmt.h into linux/ieee80211.h
d80211: move d80211_common.h to net/d80211Mohamed Abbas:
d80211: add mising sta_info_put function
Signature · 2 lines
Jiri Benc SUSE Labs
PATCH 1/14 d80211: allow for hardware crypto of default keys
From: David Kimdon <[email protected]>
Remove incorrect prohibition of hardware crypto support. This was originally present to prevent hardware crypto when more than one station interface was created for a single hardware device, the code in question is no longer correct and should be removed.
---
net/d80211/ieee80211_ioctl.c | 9 +-------- 1 files changed, 1 insertions(+), 8 deletions(-)
281859d5a1d5004285bf806286600fa49ecb117b
net/d80211/ieee80211_ioctl.c +1 -8
@@ -537,9 +537,7 @@ static int ieee80211_set_encryption(stru } key = sdata->keys[idx]; -/* Disable hwaccel for default keys when the interface is not -* the default one. -* TODO: consider adding hwaccel support for these; at least +/* TODO: consider adding hwaccel support for these; at least * Atheros key cache should be able to handle this since AP is * only transmitting frames with default keys. */ /* FIX: hw key cache can be used when only one virtual
@@ -548,11 +546,6 @@ static int ieee80211_set_encryption(stru* must be used. This should be done automatically * based on configured station devices. For the time * being, this can be only set at compile time. */ -/* FIXME: There is no more anything like "default -* interface". We should try hwaccel if there is just one -* interface - for now, hwaccel is unconditionaly -* disabled. */ - try_hwaccel =0 ; }else { set_tx_key =0 ;if (idx !=0 ) {
Signature · 1 line
1.3.0
PATCH 2/14 d80211: set default_wep_only dynamically
In reply to Jiri BencFrom: David Kimdon <[email protected]>
Without this change d80211 relies on userspace to let it know when it can configure default wep keys. It is always safe to set default_wep_only if there is a single station interface. This allows for hardware accelleration for the case of a single station interface.
---
net/d80211/ieee80211_i.h | 1 + net/d80211/ieee80211_iface.c | 4 ++++ net/d80211/ieee80211_ioctl.c | 30 ++++++++++++++++++++++++++++++ 3 files changed, 35 insertions(+), 0 deletions(-)
3498e00a7cb36a9e309bf4aefd1a012a7971afb3
net/d80211/ieee80211_i.h +1 -0
@@ -607,6 +607,7 @@ extern const struct iw_handler_def ieee8int ieee80211_set_hw_encryption (struct net_device *dev,struct sta_info *sta,u8 addr[ETH_ALEN ],struct ieee80211_key *key); +void ieee80211_update_default_wep_only (struct ieee80211_local *local);/* ieee80211_scan.c */ void ieee80211_init_scan (struct ieee80211_local *local);
net/d80211/ieee80211_iface.c +4 -0
@@ -97,6 +97,7 @@ int ieee80211_if_add(struct net_device * }list_add (&sdata->list, &local->sub_if_list); +ieee80211_update_default_wep_only (local);return 0 ;
@@ -164,6 +165,7 @@ void ieee80211_if_del_mgmt(struct ieee80void ieee80211_if_set_type (struct net_device *dev,int type) {struct ieee80211_sub_if_data *sdata =IEEE80211_DEV_TO_SUB_IF (dev); +struct ieee80211_local *local = dev->ieee80211_ptr; sdata->type = type;switch (type) {
@@ -205,6 +207,7 @@ void ieee80211_if_set_type(struct net_de dev->name, __FUNCTION__, type); }ieee80211_sysfs_change_if_type (dev); +ieee80211_update_default_wep_only (local); }/* Must be called with rtnl lock held. */
@@ -329,6 +332,7 @@ int ieee80211_if_remove(struct net_devic strcmp(name, sdata->dev->name) == 0 && sdata->dev != local->mdev) {__ieee80211_if_del (local, sdata); +ieee80211_update_default_wep_only (local);return 0 ; } }
net/d80211/ieee80211_ioctl.c +30 -0
@@ -2357,6 +2357,36 @@ static int ieee80211_ioctl_default_wep_o } +void ieee80211_update_default_wep_only (struct ieee80211_local *local) +{ +int i =0 ; +struct ieee80211_sub_if_data *sdata; + +spin_lock_bh (&local->sub_if_lock); +list_for_each_entry (sdata, &local->sub_if_list, list) { + +if (sdata->dev == local->mdev) +continue ; + +/* If there is an AP interface then depend on userspace to +set default_wep_only correctly. */ +if (sdata->type ==IEEE80211_IF_TYPE_AP ) { +spin_unlock_bh (&local->sub_if_lock); +return ; + } + + i++; + } + +if (i <=1 ) +ieee80211_ioctl_default_wep_only (local,1 ); +else +ieee80211_ioctl_default_wep_only (local,0 ); + +spin_unlock_bh (&local->sub_if_lock); +} + +static int ieee80211_ioctl_prism2_param (struct net_device *dev,struct iw_request_info *info,void *wrqu,char *extra)
Signature · 1 line
1.3.0
PATCH 3/14 d80211: fix potential interface name overflow
In reply to Jiri BencFrom: David Kimdon <[email protected]>
dev->name and ndev->name are both IFNAMSIZ in length, the ".%d" is not guarenteed to fit in ndev->name.
---
net/d80211/ieee80211_iface.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
e268081fcce1027a23420bfe74c59bf130742bce
net/d80211/ieee80211_iface.c +2 -1
@@ -56,7 +56,8 @@ int ieee80211_if_add(struct net_device *if (strlen (name) ==0 ) { i =0 ; do { - sprintf(ndev->name, "%s.%d", dev->name, i++); + snprintf(ndev->name, sizeof(ndev->name), "%s.%d", + dev->name, i++); tmp_dev = dev_get_by_name(ndev->name); if (!tmp_dev) break;
Signature · 1 line
1.3.0
PATCH 4/14 d80211: fix potential invalid array index returning key information
In reply to Jiri BencFrom: David Kimdon <[email protected]>
sdata->keys[] has NUM_DEFAULT_KEYS elements, don't access past that.
---
net/d80211/ieee80211_ioctl.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
11355b4c0aadecd31e43c5e6d5de652030aa0cf5
net/d80211/ieee80211_ioctl.c +1 -1
@@ -803,7 +803,7 @@ static int ieee80211_ioctl_get_encryptio param->sta_addr[2] == 0xff && param->sta_addr[3] == 0xff && param->sta_addr[4] == 0xff && param->sta_addr[5] == 0xff) { sta =NULL ; -if (param->u.crypt.idx >NUM_DEFAULT_KEYS ) { +if (param->u.crypt.idx >=NUM_DEFAULT_KEYS ) { param->u.crypt.idx = sdata->default_key ? sdata->default_key->keyidx :0 ;return 0 ;
Signature · 1 line
1.3.0
PATCH 5/14 d80211: remove unused references to sub interface data
In reply to Jiri BencFrom: David Kimdon <[email protected]>
In these three cases the pointer returned by IEEE80211_DEV_TO_SUB_IF() is never used.
---
net/d80211/ieee80211.c | 4 +--- net/d80211/ieee80211_iface.c | 3 +-- net/d80211/ieee80211_ioctl.c | 2 -- 3 files changed, 2 insertions(+), 7 deletions(-)
c2f74bcf14ecc48919bcdfa79ff0adaec8afb25e
net/d80211/ieee80211.c +1 -3
@@ -1362,11 +1362,9 @@ static int ieee80211_master_start_xmit(sstruct ieee80211_tx_control control;struct ieee80211_tx_packet_data *pkt_data;struct net_device *odev =NULL ; -struct ieee80211_sub_if_data *sdata, *osdata; +struct ieee80211_sub_if_data *osdata;int ret; - sdata =IEEE80211_DEV_TO_SUB_IF (dev); -/* * copy control out of the skb so other people can use skb->cb */
net/d80211/ieee80211_iface.c +1 -2
@@ -42,7 +42,7 @@ int ieee80211_if_add(struct net_device * {struct net_device *ndev, *tmp_dev;struct ieee80211_local *local = dev->ieee80211_ptr; -struct ieee80211_sub_if_data *sdata =NULL , *sdata_parent; +struct ieee80211_sub_if_data *sdata =NULL ;int ret;int i;
@@ -83,7 +83,6 @@ int ieee80211_if_add(struct net_device * sdata->type =IEEE80211_IF_TYPE_AP ; sdata->dev = ndev; sdata->local = local; - sdata_parent =IEEE80211_DEV_TO_SUB_IF (dev);ieee80211_if_sdata_init (sdata); ret =register_netdevice (ndev);
net/d80211/ieee80211_ioctl.c +0 -2
@@ -407,10 +407,8 @@ static int ieee80211_ioctl_get_info_sta(if (param->sta_addr[0 ] ==0xff && param->sta_addr[1 ] ==0xff && param->sta_addr[2 ] ==0xff && param->sta_addr[3 ] ==0xff && param->sta_addr[4 ] ==0xff && param->sta_addr[5 ] ==0xff ) { -struct ieee80211_sub_if_data *sdata;struct net_device_stats *stats; - sdata =IEEE80211_DEV_TO_SUB_IF (dev); stats =ieee80211_dev_stats (local->mdev); param->u.get_info_sta.rx_bytes = stats->rx_bytes; param->u.get_info_sta.tx_bytes = stats->tx_bytes;
Signature · 1 line
1.3.0
PATCH 6/14 d80211: fix invalid check for sub interface type AP
In reply to Jiri BencFrom: David Kimdon <[email protected]>
We should be checking the type member, not the raw pointer.
---
net/d80211/ieee80211_ioctl.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
7511a31ac07b8cb4141fe2d47abd55b9875b84a9
net/d80211/ieee80211_ioctl.c +1 -1
@@ -1996,7 +1996,7 @@ static int ieee80211_ioctl_siwscan(struc sdata->type == IEEE80211_IF_TYPE_IBSS) { ssid = sdata->u.sta.ssid; ssid_len = sdata->u.sta.ssid_len; - } else if (sdata == IEEE80211_IF_TYPE_AP) { + } else if (sdata->type == IEEE80211_IF_TYPE_AP) { ssid = sdata->u.ap.ssid; ssid_len = sdata->u.ap.ssid_len; } else
Signature · 1 line
1.3.0
PATCH 7/14 d80211: do not pass an invalid key index to set_key()
In reply to Jiri BencFrom: David Kimdon <[email protected]>
d80211: do not pass an invalid key index to set_key()
If a hardware key has not been configured then there is no point to calling DISABLE_KEY.
---
net/d80211/ieee80211_ioctl.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
0efae98fe404771fc3660f1d6023ab692149ddec
net/d80211/ieee80211_ioctl.c +3 -1
@@ -612,7 +612,9 @@ #endif /* CONFIG_D80211_VERBOSE_DEBUG */if (alg ==ALG_NONE ) { keyconf =NULL ; -if (try_hwaccel && key && local->ops->set_key && +if (try_hwaccel && key && + key->hw_key_idx !=HW_KEY_IDX_INVALID && + local->ops->set_key && (keyconf =ieee80211_key_data2conf (local, key)) !=NULL && local->ops->set_key (local_to_hw (local),DISABLE_KEY , sta_addr, keyconf, sta ? sta->aid :0 )) {
Signature · 1 line
1.3.0
PATCH 8/14 d80211: add mising sta_info_put function
In reply to Jiri BencFrom: Mohamed Abbas <[email protected]>
This is small patch adding missing sta_info_put function.
---
net/d80211/ieee80211_ioctl.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
6b29100c7e405c835eac8ebff2ff11774763da05
net/d80211/ieee80211_ioctl.c +1 -0
@@ -3048,6 +3048,7 @@ static struct iw_statistics *ieee80211_g wstats->qual.qual =100 *tmp_qual/local->hw.maxssi; wstats->qual.noise = sta->last_noise; wstats->qual.updated =IW_QUAL_ALL_UPDATED |IW_QUAL_DBM ; +sta_info_put (sta); }return wstats; }
Signature · 1 line
1.3.0
PATCH 9/14 d80211: remove pkt_type/pkt_probe_resp
In reply to Jiri BencFrom: Michael Wu <[email protected]>
Nobody uses pkt_type, and the information can be obtained from the header. This removes it and the associated code that keeps tracks of it.
---
include/net/d80211.h | 1 - net/d80211/ieee80211.c | 7 ------- net/d80211/ieee80211_i.h | 3 +-- net/d80211/ieee80211_sta.c | 17 +++++++---------- 4 files changed, 8 insertions(+), 20 deletions(-)
67e20838fff9a011cb83a02ca21d39d73313a42f
include/net/d80211.h +0 -1
@@ -135,7 +135,6 @@ struct ieee80211_low_level_stats {#define HW_KEY_IDX_INVALID -1struct ieee80211_tx_control { -enum {PKT_NORMAL =0 ,PKT_PROBE_RESP } pkt_type;int tx_rate;/* Transmit rate, given as the hw specific value for the * rate (from struct ieee80211_rate) */ int rts_cts_rate;/* Transmit rate for RTS/CTS frame, given as the hw
net/d80211/ieee80211.c +0 -7
@@ -1393,8 +1393,6 @@ #endif control.flags |=IEEE80211_TXCTL_REQ_TX_STATUS ;if (pkt_data->do_not_encrypt) control.flags |=IEEE80211_TXCTL_DO_NOT_ENCRYPT ; - control.pkt_type = - pkt_data->pkt_probe_resp ?PKT_PROBE_RESP :PKT_NORMAL ;if (pkt_data->requeue) control.flags |=IEEE80211_TXCTL_REQUEUE ; control.queue = pkt_data->queue;
@@ -1626,10 +1624,6 @@ ieee80211_mgmt_start_xmit(struct sk_buff pkt_data->ifindex = sdata->dev->ifindex; pkt_data->mgmt_iface = (sdata->type ==IEEE80211_IF_TYPE_MGMT ); -if ((fc &IEEE80211_FCTL_FTYPE ) ==IEEE80211_FTYPE_MGMT && - (fc &IEEE80211_FCTL_STYPE ) ==IEEE80211_STYPE_PROBE_RESP ) - pkt_data->pkt_probe_resp =1 ; - skb->priority =20 ;/* use hardcoded priority for mgmt TX queue */ skb->dev = sdata->local->mdev;
@@ -4048,7 +4042,6 @@ static void ieee80211_remove_tx_extra(st pkt_data->mgmt_iface = (control->type ==IEEE80211_IF_TYPE_MGMT ); pkt_data->req_tx_status = !!(control->flags &IEEE80211_TXCTL_REQ_TX_STATUS ); pkt_data->do_not_encrypt = !!(control->flags &IEEE80211_TXCTL_DO_NOT_ENCRYPT ); - pkt_data->pkt_probe_resp = (control->pkt_type ==PKT_PROBE_RESP ); pkt_data->requeue = !!(control->flags &IEEE80211_TXCTL_REQUEUE ); pkt_data->queue = control->queue;
net/d80211/ieee80211_i.h +1 -2
@@ -155,10 +155,9 @@ struct ieee80211_tx_packet_data {unsigned long jiffies; unsigned int req_tx_status:1; unsigned int do_not_encrypt:1; - unsigned int pkt_probe_resp:1; unsigned int requeue:1; - unsigned int queue:4; unsigned int mgmt_iface:1; + unsigned int queue:4; };struct ieee80211_tx_stored_packet {
net/d80211/ieee80211_sta.c +7 -10
@@ -384,7 +384,7 @@ static void ieee80211_set_associated(strstatic void ieee80211_sta_tx (struct net_device *dev,struct sk_buff *skb, -int encrypt,int probe_resp) +int encrypt) {struct ieee80211_sub_if_data *sdata;struct ieee80211_tx_packet_data *pkt_data;
@@ -398,8 +398,6 @@ static void ieee80211_sta_tx(struct net_ pkt_data->ifindex = sdata->dev->ifindex; pkt_data->mgmt_iface = (sdata->type ==IEEE80211_IF_TYPE_MGMT ); pkt_data->do_not_encrypt = !encrypt; -if (probe_resp) - pkt_data->pkt_probe_resp =1 ;dev_queue_xmit (skb); }
@@ -436,7 +434,7 @@ static void ieee80211_send_auth(struct nif (extra)memcpy (skb_put (skb, extra_len), extra, extra_len); -ieee80211_sta_tx (dev, skb, encrypt,0 ); +ieee80211_sta_tx (dev, skb, encrypt); }
@@ -573,7 +571,7 @@ static void ieee80211_send_assoc(structif (ifsta->assocreq_ies)memcpy (ifsta->assocreq_ies, ies, ifsta->assocreq_ies_len); -ieee80211_sta_tx (dev, skb,0 ,0 ); +ieee80211_sta_tx (dev, skb,0 ); }
@@ -600,7 +598,7 @@ static void ieee80211_send_deauth(structskb_put (skb,2 ); mgmt->u.deauth.reason_code =cpu_to_le16 (reason); -ieee80211_sta_tx (dev, skb,0 ,0 ); +ieee80211_sta_tx (dev, skb,0 ); }
@@ -627,7 +625,7 @@ static void ieee80211_send_disassoc(struskb_put (skb,2 ); mgmt->u.disassoc.reason_code =cpu_to_le16 (reason); -ieee80211_sta_tx (dev, skb,0 ,0 ); +ieee80211_sta_tx (dev, skb,0 ); }
@@ -803,7 +801,7 @@ static void ieee80211_send_probe_req(str *pos = rate->rate /5 ; } -ieee80211_sta_tx (dev, skb,0 ,0 ); +ieee80211_sta_tx (dev, skb,0 ); }
@@ -1693,7 +1691,7 @@ #ifdef CONFIG_D80211_IBSS_DEBUGprintk (KERN_DEBUG "%s: Sending ProbeResp to " MAC_FMT "\n" , dev->name,MAC_ARG (resp->da));#endif /* CONFIG_D80211_IBSS_DEBUG */ -ieee80211_sta_tx (dev, skb,0 ,1 ); +ieee80211_sta_tx (dev, skb,0 ); }
@@ -2046,7 +2044,6 @@ static int ieee80211_sta_join_ibss(struc }memset (&control,0 ,sizeof (control)); - control.pkt_type =PKT_PROBE_RESP ;memset (&extra,0 ,sizeof (extra)); extra.endidx = local->num_curr_rates; rate =rate_control_get_rate (local, dev, skb, &extra);
Signature · 1 line
1.3.0
PATCH 10/14 d80211: Fix errorcode in ieee80211_update_hw
In reply to Jiri BencFrom: Michael Buesch <[email protected]>
ieee80211_update_hw should return a proper error code instead of hardcoded -1.
---
net/d80211/ieee80211.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
cca5b9bc1f21e1d9a616e0f8e2fea04140a51a07
net/d80211/ieee80211.c +1 -1
@@ -4635,7 +4635,7 @@ int ieee80211_update_hw(struct ieee80211if (!hw->modes || !hw->modes->channels || !hw->modes->rates || !hw->modes->num_channels || !hw->modes->num_rates) -return -1 ; +return -EINVAL ;ieee80211_precalc_modes (local); local->hw.conf.phymode = hw->modes[0 ].mode;
Signature · 1 line
1.3.0
PATCH 11/14 d80211: move 802.11 defines to linux/ieee80211.h
In reply to Jiri BencFrom: Michael Wu <[email protected]>
This moves 802.11 defines from net/d80211.h into linux/ieee80211.h.
It also renames IEEE80211_DATA_LEN to IEEE80211_MAX_DATA_LEN to better match the other definitions.
---
include/linux/Kbuild | 1 include/linux/ieee80211.h | 107 +++++++++++++++++++++++++++++++++++++++++++++ include/net/d80211.h | 90 -------------------------------------- net/d80211/ieee80211.c | 4 +- 4 files changed, 111 insertions(+), 91 deletions(-) create mode 100644 include/linux/ieee80211.h
a2e9253024872101863b1557b116bc95cd2190ef
include/linux/Kbuild +1 -0
@@ -72,6 +72,7 @@ header-y += hysdn_if.h header-y += i2c-dev.h header-y += i8k.h header-y += icmp.h +header-y += ieee80211.h header-y += if_addr.h header-y += if_arcnet.h header-y += if_arp.h
include/linux/ieee80211.h new file +107 -0
107 lines not on this page · raw message
include/net/d80211.h +1 -89
102 lines not on this page · raw message
net/d80211/ieee80211.c +2 -2
@@ -1939,7 +1939,7 @@ static int ieee80211_change_mtu(struct n {/* FIX: what would be proper limits for MTU? * This interface uses 802.3 frames. */ -if (new_mtu <256 || new_mtu >IEEE80211_DATA_LEN -24 -6 ) { +if (new_mtu <256 || new_mtu >IEEE80211_MAX_DATA_LEN -24 -6 ) {printk (KERN_WARNING "%s: invalid MTU %d\n" , dev->name, new_mtu);return -EINVAL ;
@@ -1957,7 +1957,7 @@ static int ieee80211_change_mtu_apdev(st {/* FIX: what would be proper limits for MTU? * This interface uses 802.11 frames. */ -if (new_mtu <256 || new_mtu >IEEE80211_DATA_LEN ) { +if (new_mtu <256 || new_mtu >IEEE80211_MAX_DATA_LEN ) {printk (KERN_WARNING "%s: invalid MTU %d\n" , dev->name, new_mtu);return -EINVAL ;
Signature · 1 line
1.3.0
PATCH 12/14 d80211: merge d80211_shared.h into d80211.h
In reply to Jiri BencFrom: Michael Wu <[email protected]>
This merges d80211_shared.h into d80211.h.
---
include/net/d80211.h | 32 +++++++++++++++++++++++++++++- include/net/d80211_shared.h | 46 ------------------------------------------- 2 files changed, 31 insertions(+), 47 deletions(-) delete mode 100644 include/net/d80211_shared.h
3dbbcd7c8aaec66320f38835ceea04f5ce4bc456
include/net/d80211.h +31 -1
@@ -16,7 +16,6 @@ #include <linux/skbuff.h>#include <linux/wireless.h> #include <linux/device.h> #include <linux/ieee80211.h> -#include "d80211_shared.h" /* Note! Only ieee80211_tx_status_irqsafe() and ieee80211_rx_irqsafe() can be * called in hardware interrupt context. The low-level driver must not call any
@@ -47,6 +46,10 @@ #include "d80211_shared.h"#define IEEE80211_VERSION 2 +#define IEEE80211_CHAN_W_SCAN 0x00000001 +#define IEEE80211_CHAN_W_ACTIVE_SCAN 0x00000002 +#define IEEE80211_CHAN_W_IBSS 0x00000004 +/* Channel information structure. Low-level driver is expected to fill in chan, * freq, and val fields. Other fields will be filled in by 80211.o based on * hostapd information and low-level driver does not need to use them. The
@@ -61,6 +64,22 @@ struct ieee80211_channel {unsigned char antenna_max; }; +#define IEEE80211_RATE_ERP 0x00000001 +#define IEEE80211_RATE_BASIC 0x00000002 +#define IEEE80211_RATE_PREAMBLE2 0x00000004 +#define IEEE80211_RATE_SUPPORTED 0x00000010 +#define IEEE80211_RATE_OFDM 0x00000020 +#define IEEE80211_RATE_CCK 0x00000040 +#define IEEE80211_RATE_TURBO 0x00000080 +#define IEEE80211_RATE_MANDATORY 0x00000100 + +#define IEEE80211_RATE_CCK_2 (IEEE80211_RATE_CCK | IEEE80211_RATE_PREAMBLE2) +#define IEEE80211_RATE_MODULATION (f) \ +(f & (IEEE80211_RATE_CCK | IEEE80211_RATE_OFDM)) + +/* Low-level driver should set PREAMBLE2, OFDM, CCK, and TURBO flags. +* BASIC, SUPPORTED, ERP, and MANDATORY flags are set in 80211.o based on the +* configuration. */ struct ieee80211_rate {int rate;/* rate in 100 kbps */ int val;/* hw specific value for the rate */
@@ -77,6 +96,17 @@ struct ieee80211_rate {* optimizing channel utilization estimates */ }; +/* 802.11g is backwards-compatible with 802.11b, so a wlan card can +* actually be both in 11b and 11g modes at the same time. */ +enum { +MODE_IEEE80211A =0 /* IEEE 802.11a */ , +MODE_IEEE80211B =1 /* IEEE 802.11b only */ , +MODE_ATHEROS_TURBO =2 /* Atheros Turbo mode (2x.11a at 5 GHz) */ , +MODE_IEEE80211G =3 /* IEEE 802.11g (and 802.11b compatibility) */ , +MODE_ATHEROS_TURBOG =4 /* Atheros Turbo mode (2x.11g at 2.4 GHz) */ , +NUM_IEEE80211_MODES =5 +}; +struct ieee80211_hw_modes {int mode;int num_channels;
include/net/d80211_shared.h deleted +0 -46
46 lines not on this page · raw message
Signature · 1 line
1.3.0
PATCH 13/14 d80211: merge d80211_mgmt.h into linux/ieee80211.h
In reply to Jiri BencFrom: Michael Wu <[email protected]>
This merges d80211_mgmt.h with linux/ieee80211.h, to keep all the general 802.11 definitions in one place.
---
drivers/net/wireless/d80211/bcm43xx/bcm43xx.h | 1 include/linux/ieee80211.h | 208 +++++++++++++++++++++++ include/net/d80211_mgmt.h | 223 ------------------------- net/d80211/ieee80211.c | 1 net/d80211/ieee80211_iface.c | 1 net/d80211/ieee80211_ioctl.c | 1 net/d80211/ieee80211_sta.c | 1 7 files changed, 208 insertions(+), 228 deletions(-) delete mode 100644 include/net/d80211_mgmt.h
3c00986b08e969cc141bd094dfd8e2f20340c8c7
drivers/net/wireless/d80211/bcm43xx/bcm43xx.h +0 -1
@@ -14,7 +14,6 @@ #include <asm/io.h>#include <linux/ssb.h> #include <linux/wireless.h> #include <net/d80211.h> -#include <net/d80211_mgmt.h> #include <net/d80211_common.h> #include "bcm43xx_debugfs.h"
include/linux/ieee80211.h +208 -0
212 lines not on this page · raw message
include/net/d80211_mgmt.h deleted +0 -223
223 lines not on this page · raw message
net/d80211/ieee80211.c +0 -1
@@ -23,7 +23,6 @@ #include <linux/compiler.h>#include <linux/bitmap.h> #include <net/d80211_common.h> -#include <net/d80211_mgmt.h> #include "ieee80211_i.h" #include "ieee80211_rate.h" #include "wep.h"
net/d80211/ieee80211_iface.c +0 -1
@@ -12,7 +12,6 @@ #include <linux/if_arp.h>#include <linux/netdevice.h> #include <linux/rtnetlink.h> #include <net/d80211.h> -#include <net/d80211_mgmt.h> #include "ieee80211_i.h" #include "sta_info.h"
net/d80211/ieee80211_ioctl.c +0 -1
@@ -20,7 +20,6 @@ #include <net/iw_handler.h>#include <asm/uaccess.h> #include <net/d80211.h> -#include <net/d80211_mgmt.h> #include "ieee80211_i.h" #include "hostapd_ioctl.h" #include "ieee80211_rate.h"
net/d80211/ieee80211_sta.c +0 -1
@@ -26,7 +26,6 @@ #include <asm/types.h>#include <asm/delay.h> #include <net/d80211.h> -#include <net/d80211_mgmt.h> #include "ieee80211_i.h" #include "ieee80211_rate.h" #include "hostapd_ioctl.h"
Signature · 1 line
1.3.0
PATCH 14/14 d80211: move d80211_common.h to net/d80211
In reply to Jiri BencFrom: Michael Wu <[email protected]>
This moves d80211_common.h to net/d80211/ieee80211_common.h since d80211 drivers should not include this file.
---
drivers/net/wireless/d80211/bcm43xx/bcm43xx.h | 1 include/net/d80211_common.h | 98 ------------------------- net/d80211/ieee80211.c | 2 - net/d80211/ieee80211_common.h | 98 +++++++++++++++++++++++++ net/d80211/wpa.c | 2 - 5 files changed, 100 insertions(+), 101 deletions(-) delete mode 100644 include/net/d80211_common.h create mode 100644 net/d80211/ieee80211_common.h
4ae94181f808da96352478c6d4102e3b0b5dfaac
drivers/net/wireless/d80211/bcm43xx/bcm43xx.h +0 -1
@@ -14,7 +14,6 @@ #include <asm/io.h>#include <linux/ssb.h> #include <linux/wireless.h> #include <net/d80211.h> -#include <net/d80211_common.h> #include "bcm43xx_debugfs.h" #include "bcm43xx_leds.h"
include/net/d80211_common.h deleted +0 -98
98 lines not on this page · raw message
net/d80211/ieee80211.c +1 -1
@@ -22,7 +22,7 @@ #include <net/iw_handler.h>#include <linux/compiler.h> #include <linux/bitmap.h> -#include <net/d80211_common.h> +#include "ieee80211_common.h" #include "ieee80211_i.h" #include "ieee80211_rate.h" #include "wep.h"
net/d80211/ieee80211_common.h new file +98 -0
98 lines not on this page · raw message
net/d80211/wpa.c +1 -1
@@ -14,7 +14,7 @@ #include <linux/compiler.h>#include <net/iw_handler.h> #include <net/d80211.h> -#include <net/d80211_common.h> +#include "ieee80211_common.h" #include "ieee80211_i.h" #include "michael.h" #include "tkip.h"
Signature · 1 line
1.3.0