diff options
author | Dan Williams <dcbw@redhat.com> | 2009-02-11 17:17:10 -0500 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-02-27 14:51:41 -0500 |
commit | 1ea893fde29d8cf1639da8989f4b843dc3283ca8 (patch) | |
tree | b942df0bc99ef1568aab1ce4e42969e9eaf5b3db /drivers/net/wireless/hostap/hostap_hw.c | |
parent | 4d8faf6937fd7ada1f523b1cf565ffd2a0623e8c (diff) | |
download | blackbird-op-linux-1ea893fde29d8cf1639da8989f4b843dc3283ca8.tar.gz blackbird-op-linux-1ea893fde29d8cf1639da8989f4b843dc3283ca8.zip |
hostap: convert usage of net/ieee80211.h to linux/ieee80211.h
So that net/ieee80211.h can be made private to ipw2x00 in a follow-up.
Signed-off-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/hostap/hostap_hw.c')
-rw-r--r-- | drivers/net/wireless/hostap/hostap_hw.c | 24 |
1 files changed, 11 insertions, 13 deletions
diff --git a/drivers/net/wireless/hostap/hostap_hw.c b/drivers/net/wireless/hostap/hostap_hw.c index 0f27059bbe85..3d9e7b7a17b0 100644 --- a/drivers/net/wireless/hostap/hostap_hw.c +++ b/drivers/net/wireless/hostap/hostap_hw.c @@ -46,7 +46,6 @@ #include <linux/rtnetlink.h> #include <linux/wireless.h> #include <net/iw_handler.h> -#include <net/ieee80211.h> #include <net/lib80211.h> #include <asm/irq.h> @@ -1840,8 +1839,8 @@ static int prism2_tx_80211(struct sk_buff *skb, struct net_device *dev) hdr_len = 24; skb_copy_from_linear_data(skb, &txdesc.frame_control, hdr_len); fc = le16_to_cpu(txdesc.frame_control); - if (WLAN_FC_GET_TYPE(fc) == IEEE80211_FTYPE_DATA && - (fc & IEEE80211_FCTL_FROMDS) && (fc & IEEE80211_FCTL_TODS) && + if (ieee80211_is_data(txdesc.frame_control) && + ieee80211_has_a4(txdesc.frame_control) && skb->len >= 30) { /* Addr4 */ skb_copy_from_linear_data_offset(skb, hdr_len, txdesc.addr4, @@ -2082,7 +2081,7 @@ static void hostap_rx_skb(local_info_t *local, struct sk_buff *skb) stats.rate = rxdesc->rate; /* Convert Prism2 RX structure into IEEE 802.11 header */ - hdrlen = hostap_80211_get_hdrlen(le16_to_cpu(rxdesc->frame_control)); + hdrlen = hostap_80211_get_hdrlen(rxdesc->frame_control); if (hdrlen > rx_hdrlen) hdrlen = rx_hdrlen; @@ -2204,7 +2203,7 @@ static void hostap_tx_callback(local_info_t *local, return; } - hdrlen = hostap_80211_get_hdrlen(le16_to_cpu(txdesc->frame_control)); + hdrlen = hostap_80211_get_hdrlen(txdesc->frame_control); len = le16_to_cpu(txdesc->data_len); skb = dev_alloc_skb(hdrlen + len); if (skb == NULL) { @@ -2315,8 +2314,7 @@ static void hostap_sta_tx_exc_tasklet(unsigned long data) if (skb->len >= sizeof(*txdesc)) { /* Convert Prism2 RX structure into IEEE 802.11 header */ - u16 fc = le16_to_cpu(txdesc->frame_control); - int hdrlen = hostap_80211_get_hdrlen(fc); + int hdrlen = hostap_80211_get_hdrlen(txdesc->frame_control); memmove(skb_pull(skb, sizeof(*txdesc) - hdrlen), &txdesc->frame_control, hdrlen); @@ -2394,12 +2392,12 @@ static void prism2_txexc(local_info_t *local) PDEBUG(DEBUG_EXTRA, " retry_count=%d tx_rate=%d fc=0x%04x " "(%s%s%s::%d%s%s)\n", txdesc.retry_count, txdesc.tx_rate, fc, - WLAN_FC_GET_TYPE(fc) == IEEE80211_FTYPE_MGMT ? "Mgmt" : "", - WLAN_FC_GET_TYPE(fc) == IEEE80211_FTYPE_CTL ? "Ctrl" : "", - WLAN_FC_GET_TYPE(fc) == IEEE80211_FTYPE_DATA ? "Data" : "", - WLAN_FC_GET_STYPE(fc) >> 4, - fc & IEEE80211_FCTL_TODS ? " ToDS" : "", - fc & IEEE80211_FCTL_FROMDS ? " FromDS" : ""); + ieee80211_is_mgmt(txdesc.frame_control) ? "Mgmt" : "", + ieee80211_is_ctl(txdesc.frame_control) ? "Ctrl" : "", + ieee80211_is_data(txdesc.frame_control) ? "Data" : "", + (fc & IEEE80211_FCTL_STYPE) >> 4, + ieee80211_has_tods(txdesc.frame_control) ? " ToDS" : "", + ieee80211_has_fromds(txdesc.frame_control) ? " FromDS" : ""); PDEBUG(DEBUG_EXTRA, " A1=%pM A2=%pM A3=%pM A4=%pM\n", txdesc.addr1, txdesc.addr2, txdesc.addr3, txdesc.addr4); |