diff options
Diffstat (limited to 'drivers/net/wireless/hostap/hostap_ap.c')
-rw-r--r-- | drivers/net/wireless/hostap/hostap_ap.c | 80 |
1 files changed, 40 insertions, 40 deletions
diff --git a/drivers/net/wireless/hostap/hostap_ap.c b/drivers/net/wireless/hostap/hostap_ap.c index 930cef8367f2..9da94ab7f05f 100644 --- a/drivers/net/wireless/hostap/hostap_ap.c +++ b/drivers/net/wireless/hostap/hostap_ap.c | |||
@@ -591,14 +591,14 @@ static void hostap_ap_tx_cb(struct sk_buff *skb, int ok, void *data) | |||
591 | { | 591 | { |
592 | struct ap_data *ap = data; | 592 | struct ap_data *ap = data; |
593 | u16 fc; | 593 | u16 fc; |
594 | struct ieee80211_hdr *hdr; | 594 | struct ieee80211_hdr_4addr *hdr; |
595 | 595 | ||
596 | if (!ap->local->hostapd || !ap->local->apdev) { | 596 | if (!ap->local->hostapd || !ap->local->apdev) { |
597 | dev_kfree_skb(skb); | 597 | dev_kfree_skb(skb); |
598 | return; | 598 | return; |
599 | } | 599 | } |
600 | 600 | ||
601 | hdr = (struct ieee80211_hdr *) skb->data; | 601 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
602 | fc = le16_to_cpu(hdr->frame_ctl); | 602 | fc = le16_to_cpu(hdr->frame_ctl); |
603 | 603 | ||
604 | /* Pass the TX callback frame to the hostapd; use 802.11 header version | 604 | /* Pass the TX callback frame to the hostapd; use 802.11 header version |
@@ -623,7 +623,7 @@ static void hostap_ap_tx_cb_auth(struct sk_buff *skb, int ok, void *data) | |||
623 | { | 623 | { |
624 | struct ap_data *ap = data; | 624 | struct ap_data *ap = data; |
625 | struct net_device *dev = ap->local->dev; | 625 | struct net_device *dev = ap->local->dev; |
626 | struct ieee80211_hdr *hdr; | 626 | struct ieee80211_hdr_4addr *hdr; |
627 | u16 fc, *pos, auth_alg, auth_transaction, status; | 627 | u16 fc, *pos, auth_alg, auth_transaction, status; |
628 | struct sta_info *sta = NULL; | 628 | struct sta_info *sta = NULL; |
629 | char *txt = NULL; | 629 | char *txt = NULL; |
@@ -633,7 +633,7 @@ static void hostap_ap_tx_cb_auth(struct sk_buff *skb, int ok, void *data) | |||
633 | return; | 633 | return; |
634 | } | 634 | } |
635 | 635 | ||
636 | hdr = (struct ieee80211_hdr *) skb->data; | 636 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
637 | fc = le16_to_cpu(hdr->frame_ctl); | 637 | fc = le16_to_cpu(hdr->frame_ctl); |
638 | if (WLAN_FC_GET_TYPE(fc) != IEEE80211_FTYPE_MGMT || | 638 | if (WLAN_FC_GET_TYPE(fc) != IEEE80211_FTYPE_MGMT || |
639 | WLAN_FC_GET_STYPE(fc) != IEEE80211_STYPE_AUTH || | 639 | WLAN_FC_GET_STYPE(fc) != IEEE80211_STYPE_AUTH || |
@@ -692,7 +692,7 @@ static void hostap_ap_tx_cb_assoc(struct sk_buff *skb, int ok, void *data) | |||
692 | { | 692 | { |
693 | struct ap_data *ap = data; | 693 | struct ap_data *ap = data; |
694 | struct net_device *dev = ap->local->dev; | 694 | struct net_device *dev = ap->local->dev; |
695 | struct ieee80211_hdr *hdr; | 695 | struct ieee80211_hdr_4addr *hdr; |
696 | u16 fc, *pos, status; | 696 | u16 fc, *pos, status; |
697 | struct sta_info *sta = NULL; | 697 | struct sta_info *sta = NULL; |
698 | char *txt = NULL; | 698 | char *txt = NULL; |
@@ -702,7 +702,7 @@ static void hostap_ap_tx_cb_assoc(struct sk_buff *skb, int ok, void *data) | |||
702 | return; | 702 | return; |
703 | } | 703 | } |
704 | 704 | ||
705 | hdr = (struct ieee80211_hdr *) skb->data; | 705 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
706 | fc = le16_to_cpu(hdr->frame_ctl); | 706 | fc = le16_to_cpu(hdr->frame_ctl); |
707 | if (WLAN_FC_GET_TYPE(fc) != IEEE80211_FTYPE_MGMT || | 707 | if (WLAN_FC_GET_TYPE(fc) != IEEE80211_FTYPE_MGMT || |
708 | (WLAN_FC_GET_STYPE(fc) != IEEE80211_STYPE_ASSOC_RESP && | 708 | (WLAN_FC_GET_STYPE(fc) != IEEE80211_STYPE_ASSOC_RESP && |
@@ -757,12 +757,12 @@ static void hostap_ap_tx_cb_assoc(struct sk_buff *skb, int ok, void *data) | |||
757 | static void hostap_ap_tx_cb_poll(struct sk_buff *skb, int ok, void *data) | 757 | static void hostap_ap_tx_cb_poll(struct sk_buff *skb, int ok, void *data) |
758 | { | 758 | { |
759 | struct ap_data *ap = data; | 759 | struct ap_data *ap = data; |
760 | struct ieee80211_hdr *hdr; | 760 | struct ieee80211_hdr_4addr *hdr; |
761 | struct sta_info *sta; | 761 | struct sta_info *sta; |
762 | 762 | ||
763 | if (skb->len < 24) | 763 | if (skb->len < 24) |
764 | goto fail; | 764 | goto fail; |
765 | hdr = (struct ieee80211_hdr *) skb->data; | 765 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
766 | if (ok) { | 766 | if (ok) { |
767 | spin_lock(&ap->sta_table_lock); | 767 | spin_lock(&ap->sta_table_lock); |
768 | sta = ap_get_sta(ap, hdr->addr1); | 768 | sta = ap_get_sta(ap, hdr->addr1); |
@@ -918,7 +918,7 @@ static void prism2_send_mgmt(struct net_device *dev, | |||
918 | { | 918 | { |
919 | struct hostap_interface *iface; | 919 | struct hostap_interface *iface; |
920 | local_info_t *local; | 920 | local_info_t *local; |
921 | struct ieee80211_hdr *hdr; | 921 | struct ieee80211_hdr_4addr *hdr; |
922 | u16 fc; | 922 | u16 fc; |
923 | struct sk_buff *skb; | 923 | struct sk_buff *skb; |
924 | struct hostap_skb_tx_data *meta; | 924 | struct hostap_skb_tx_data *meta; |
@@ -944,7 +944,7 @@ static void prism2_send_mgmt(struct net_device *dev, | |||
944 | 944 | ||
945 | fc = type_subtype; | 945 | fc = type_subtype; |
946 | hdrlen = hostap_80211_get_hdrlen(fc); | 946 | hdrlen = hostap_80211_get_hdrlen(fc); |
947 | hdr = (struct ieee80211_hdr *) skb_put(skb, hdrlen); | 947 | hdr = (struct ieee80211_hdr_4addr *) skb_put(skb, hdrlen); |
948 | if (body) | 948 | if (body) |
949 | memcpy(skb_put(skb, body_len), body, body_len); | 949 | memcpy(skb_put(skb, body_len), body, body_len); |
950 | 950 | ||
@@ -1256,14 +1256,14 @@ static char * ap_auth_make_challenge(struct ap_data *ap) | |||
1256 | } | 1256 | } |
1257 | 1257 | ||
1258 | skb = dev_alloc_skb(WLAN_AUTH_CHALLENGE_LEN + | 1258 | skb = dev_alloc_skb(WLAN_AUTH_CHALLENGE_LEN + |
1259 | ap->crypt->extra_prefix_len + | 1259 | ap->crypt->extra_mpdu_prefix_len + |
1260 | ap->crypt->extra_postfix_len); | 1260 | ap->crypt->extra_mpdu_postfix_len); |
1261 | if (skb == NULL) { | 1261 | if (skb == NULL) { |
1262 | kfree(tmpbuf); | 1262 | kfree(tmpbuf); |
1263 | return NULL; | 1263 | return NULL; |
1264 | } | 1264 | } |
1265 | 1265 | ||
1266 | skb_reserve(skb, ap->crypt->extra_prefix_len); | 1266 | skb_reserve(skb, ap->crypt->extra_mpdu_prefix_len); |
1267 | memset(skb_put(skb, WLAN_AUTH_CHALLENGE_LEN), 0, | 1267 | memset(skb_put(skb, WLAN_AUTH_CHALLENGE_LEN), 0, |
1268 | WLAN_AUTH_CHALLENGE_LEN); | 1268 | WLAN_AUTH_CHALLENGE_LEN); |
1269 | if (ap->crypt->encrypt_mpdu(skb, 0, ap->crypt_priv)) { | 1269 | if (ap->crypt->encrypt_mpdu(skb, 0, ap->crypt_priv)) { |
@@ -1272,7 +1272,7 @@ static char * ap_auth_make_challenge(struct ap_data *ap) | |||
1272 | return NULL; | 1272 | return NULL; |
1273 | } | 1273 | } |
1274 | 1274 | ||
1275 | memcpy(tmpbuf, skb->data + ap->crypt->extra_prefix_len, | 1275 | memcpy(tmpbuf, skb->data + ap->crypt->extra_mpdu_prefix_len, |
1276 | WLAN_AUTH_CHALLENGE_LEN); | 1276 | WLAN_AUTH_CHALLENGE_LEN); |
1277 | dev_kfree_skb(skb); | 1277 | dev_kfree_skb(skb); |
1278 | 1278 | ||
@@ -1285,7 +1285,7 @@ static void handle_authen(local_info_t *local, struct sk_buff *skb, | |||
1285 | struct hostap_80211_rx_status *rx_stats) | 1285 | struct hostap_80211_rx_status *rx_stats) |
1286 | { | 1286 | { |
1287 | struct net_device *dev = local->dev; | 1287 | struct net_device *dev = local->dev; |
1288 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; | 1288 | struct ieee80211_hdr_4addr *hdr = (struct ieee80211_hdr_4addr *) skb->data; |
1289 | size_t hdrlen; | 1289 | size_t hdrlen; |
1290 | struct ap_data *ap = local->ap; | 1290 | struct ap_data *ap = local->ap; |
1291 | char body[8 + WLAN_AUTH_CHALLENGE_LEN], *challenge = NULL; | 1291 | char body[8 + WLAN_AUTH_CHALLENGE_LEN], *challenge = NULL; |
@@ -1498,7 +1498,7 @@ static void handle_assoc(local_info_t *local, struct sk_buff *skb, | |||
1498 | struct hostap_80211_rx_status *rx_stats, int reassoc) | 1498 | struct hostap_80211_rx_status *rx_stats, int reassoc) |
1499 | { | 1499 | { |
1500 | struct net_device *dev = local->dev; | 1500 | struct net_device *dev = local->dev; |
1501 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; | 1501 | struct ieee80211_hdr_4addr *hdr = (struct ieee80211_hdr_4addr *) skb->data; |
1502 | char body[12], *p, *lpos; | 1502 | char body[12], *p, *lpos; |
1503 | int len, left; | 1503 | int len, left; |
1504 | u16 *pos; | 1504 | u16 *pos; |
@@ -1705,7 +1705,7 @@ static void handle_deauth(local_info_t *local, struct sk_buff *skb, | |||
1705 | struct hostap_80211_rx_status *rx_stats) | 1705 | struct hostap_80211_rx_status *rx_stats) |
1706 | { | 1706 | { |
1707 | struct net_device *dev = local->dev; | 1707 | struct net_device *dev = local->dev; |
1708 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; | 1708 | struct ieee80211_hdr_4addr *hdr = (struct ieee80211_hdr_4addr *) skb->data; |
1709 | char *body = (char *) (skb->data + IEEE80211_MGMT_HDR_LEN); | 1709 | char *body = (char *) (skb->data + IEEE80211_MGMT_HDR_LEN); |
1710 | int len; | 1710 | int len; |
1711 | u16 reason_code, *pos; | 1711 | u16 reason_code, *pos; |
@@ -1746,7 +1746,7 @@ static void handle_disassoc(local_info_t *local, struct sk_buff *skb, | |||
1746 | struct hostap_80211_rx_status *rx_stats) | 1746 | struct hostap_80211_rx_status *rx_stats) |
1747 | { | 1747 | { |
1748 | struct net_device *dev = local->dev; | 1748 | struct net_device *dev = local->dev; |
1749 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; | 1749 | struct ieee80211_hdr_4addr *hdr = (struct ieee80211_hdr_4addr *) skb->data; |
1750 | char *body = skb->data + IEEE80211_MGMT_HDR_LEN; | 1750 | char *body = skb->data + IEEE80211_MGMT_HDR_LEN; |
1751 | int len; | 1751 | int len; |
1752 | u16 reason_code, *pos; | 1752 | u16 reason_code, *pos; |
@@ -1784,7 +1784,7 @@ static void handle_disassoc(local_info_t *local, struct sk_buff *skb, | |||
1784 | 1784 | ||
1785 | /* Called only as a scheduled task for pending AP frames. */ | 1785 | /* Called only as a scheduled task for pending AP frames. */ |
1786 | static void ap_handle_data_nullfunc(local_info_t *local, | 1786 | static void ap_handle_data_nullfunc(local_info_t *local, |
1787 | struct ieee80211_hdr *hdr) | 1787 | struct ieee80211_hdr_4addr *hdr) |
1788 | { | 1788 | { |
1789 | struct net_device *dev = local->dev; | 1789 | struct net_device *dev = local->dev; |
1790 | 1790 | ||
@@ -1801,7 +1801,7 @@ static void ap_handle_data_nullfunc(local_info_t *local, | |||
1801 | 1801 | ||
1802 | /* Called only as a scheduled task for pending AP frames. */ | 1802 | /* Called only as a scheduled task for pending AP frames. */ |
1803 | static void ap_handle_dropped_data(local_info_t *local, | 1803 | static void ap_handle_dropped_data(local_info_t *local, |
1804 | struct ieee80211_hdr *hdr) | 1804 | struct ieee80211_hdr_4addr *hdr) |
1805 | { | 1805 | { |
1806 | struct net_device *dev = local->dev; | 1806 | struct net_device *dev = local->dev; |
1807 | struct sta_info *sta; | 1807 | struct sta_info *sta; |
@@ -1860,7 +1860,7 @@ static void pspoll_send_buffered(local_info_t *local, struct sta_info *sta, | |||
1860 | 1860 | ||
1861 | /* Called only as a scheduled task for pending AP frames. */ | 1861 | /* Called only as a scheduled task for pending AP frames. */ |
1862 | static void handle_pspoll(local_info_t *local, | 1862 | static void handle_pspoll(local_info_t *local, |
1863 | struct ieee80211_hdr *hdr, | 1863 | struct ieee80211_hdr_4addr *hdr, |
1864 | struct hostap_80211_rx_status *rx_stats) | 1864 | struct hostap_80211_rx_status *rx_stats) |
1865 | { | 1865 | { |
1866 | struct net_device *dev = local->dev; | 1866 | struct net_device *dev = local->dev; |
@@ -1979,7 +1979,7 @@ static void handle_wds_oper_queue(void *data) | |||
1979 | static void handle_beacon(local_info_t *local, struct sk_buff *skb, | 1979 | static void handle_beacon(local_info_t *local, struct sk_buff *skb, |
1980 | struct hostap_80211_rx_status *rx_stats) | 1980 | struct hostap_80211_rx_status *rx_stats) |
1981 | { | 1981 | { |
1982 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *) skb->data; | 1982 | struct ieee80211_hdr_4addr *hdr = (struct ieee80211_hdr_4addr *) skb->data; |
1983 | char *body = skb->data + IEEE80211_MGMT_HDR_LEN; | 1983 | char *body = skb->data + IEEE80211_MGMT_HDR_LEN; |
1984 | int len, left; | 1984 | int len, left; |
1985 | u16 *pos, beacon_int, capability; | 1985 | u16 *pos, beacon_int, capability; |
@@ -2137,11 +2137,11 @@ static void handle_ap_item(local_info_t *local, struct sk_buff *skb, | |||
2137 | struct net_device *dev = local->dev; | 2137 | struct net_device *dev = local->dev; |
2138 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ | 2138 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ |
2139 | u16 fc, type, stype; | 2139 | u16 fc, type, stype; |
2140 | struct ieee80211_hdr *hdr; | 2140 | struct ieee80211_hdr_4addr *hdr; |
2141 | 2141 | ||
2142 | /* FIX: should give skb->len to handler functions and check that the | 2142 | /* FIX: should give skb->len to handler functions and check that the |
2143 | * buffer is long enough */ | 2143 | * buffer is long enough */ |
2144 | hdr = (struct ieee80211_hdr *) skb->data; | 2144 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
2145 | fc = le16_to_cpu(hdr->frame_ctl); | 2145 | fc = le16_to_cpu(hdr->frame_ctl); |
2146 | type = WLAN_FC_GET_TYPE(fc); | 2146 | type = WLAN_FC_GET_TYPE(fc); |
2147 | stype = WLAN_FC_GET_STYPE(fc); | 2147 | stype = WLAN_FC_GET_STYPE(fc); |
@@ -2258,7 +2258,7 @@ void hostap_rx(struct net_device *dev, struct sk_buff *skb, | |||
2258 | struct hostap_interface *iface; | 2258 | struct hostap_interface *iface; |
2259 | local_info_t *local; | 2259 | local_info_t *local; |
2260 | u16 fc; | 2260 | u16 fc; |
2261 | struct ieee80211_hdr *hdr; | 2261 | struct ieee80211_hdr_4addr *hdr; |
2262 | 2262 | ||
2263 | iface = netdev_priv(dev); | 2263 | iface = netdev_priv(dev); |
2264 | local = iface->local; | 2264 | local = iface->local; |
@@ -2268,7 +2268,7 @@ void hostap_rx(struct net_device *dev, struct sk_buff *skb, | |||
2268 | 2268 | ||
2269 | local->stats.rx_packets++; | 2269 | local->stats.rx_packets++; |
2270 | 2270 | ||
2271 | hdr = (struct ieee80211_hdr *) skb->data; | 2271 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
2272 | fc = le16_to_cpu(hdr->frame_ctl); | 2272 | fc = le16_to_cpu(hdr->frame_ctl); |
2273 | 2273 | ||
2274 | if (local->ap->ap_policy == AP_OTHER_AP_SKIP_ALL && | 2274 | if (local->ap->ap_policy == AP_OTHER_AP_SKIP_ALL && |
@@ -2289,7 +2289,7 @@ void hostap_rx(struct net_device *dev, struct sk_buff *skb, | |||
2289 | static void schedule_packet_send(local_info_t *local, struct sta_info *sta) | 2289 | static void schedule_packet_send(local_info_t *local, struct sta_info *sta) |
2290 | { | 2290 | { |
2291 | struct sk_buff *skb; | 2291 | struct sk_buff *skb; |
2292 | struct ieee80211_hdr *hdr; | 2292 | struct ieee80211_hdr_4addr *hdr; |
2293 | struct hostap_80211_rx_status rx_stats; | 2293 | struct hostap_80211_rx_status rx_stats; |
2294 | 2294 | ||
2295 | if (skb_queue_empty(&sta->tx_buf)) | 2295 | if (skb_queue_empty(&sta->tx_buf)) |
@@ -2302,7 +2302,7 @@ static void schedule_packet_send(local_info_t *local, struct sta_info *sta) | |||
2302 | return; | 2302 | return; |
2303 | } | 2303 | } |
2304 | 2304 | ||
2305 | hdr = (struct ieee80211_hdr *) skb_put(skb, 16); | 2305 | hdr = (struct ieee80211_hdr_4addr *) skb_put(skb, 16); |
2306 | 2306 | ||
2307 | /* Generate a fake pspoll frame to start packet delivery */ | 2307 | /* Generate a fake pspoll frame to start packet delivery */ |
2308 | hdr->frame_ctl = __constant_cpu_to_le16( | 2308 | hdr->frame_ctl = __constant_cpu_to_le16( |
@@ -2349,7 +2349,7 @@ static int prism2_ap_get_sta_qual(local_info_t *local, struct sockaddr addr[], | |||
2349 | qual[count].noise = HFA384X_LEVEL_TO_dBm(sta->last_rx_silence); | 2349 | qual[count].noise = HFA384X_LEVEL_TO_dBm(sta->last_rx_silence); |
2350 | qual[count].updated = sta->last_rx_updated; | 2350 | qual[count].updated = sta->last_rx_updated; |
2351 | 2351 | ||
2352 | sta->last_rx_updated = 0; | 2352 | sta->last_rx_updated = IW_QUAL_DBM; |
2353 | 2353 | ||
2354 | count++; | 2354 | count++; |
2355 | if (count >= buf_size) | 2355 | if (count >= buf_size) |
@@ -2467,7 +2467,7 @@ static int prism2_ap_translate_scan(struct net_device *dev, char *buffer) | |||
2467 | } | 2467 | } |
2468 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ | 2468 | #endif /* PRISM2_NO_KERNEL_IEEE80211_MGMT */ |
2469 | 2469 | ||
2470 | sta->last_rx_updated = 0; | 2470 | sta->last_rx_updated = IW_QUAL_DBM; |
2471 | 2471 | ||
2472 | /* To be continued, we should make good use of IWEVCUSTOM */ | 2472 | /* To be continued, we should make good use of IWEVCUSTOM */ |
2473 | } | 2473 | } |
@@ -2685,7 +2685,7 @@ ap_tx_ret hostap_handle_sta_tx(local_info_t *local, struct hostap_tx_data *tx) | |||
2685 | struct sta_info *sta = NULL; | 2685 | struct sta_info *sta = NULL; |
2686 | struct sk_buff *skb = tx->skb; | 2686 | struct sk_buff *skb = tx->skb; |
2687 | int set_tim, ret; | 2687 | int set_tim, ret; |
2688 | struct ieee80211_hdr *hdr; | 2688 | struct ieee80211_hdr_4addr *hdr; |
2689 | struct hostap_skb_tx_data *meta; | 2689 | struct hostap_skb_tx_data *meta; |
2690 | 2690 | ||
2691 | meta = (struct hostap_skb_tx_data *) skb->cb; | 2691 | meta = (struct hostap_skb_tx_data *) skb->cb; |
@@ -2694,7 +2694,7 @@ ap_tx_ret hostap_handle_sta_tx(local_info_t *local, struct hostap_tx_data *tx) | |||
2694 | meta->iface->type == HOSTAP_INTERFACE_STA) | 2694 | meta->iface->type == HOSTAP_INTERFACE_STA) |
2695 | goto out; | 2695 | goto out; |
2696 | 2696 | ||
2697 | hdr = (struct ieee80211_hdr *) skb->data; | 2697 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
2698 | 2698 | ||
2699 | if (hdr->addr1[0] & 0x01) { | 2699 | if (hdr->addr1[0] & 0x01) { |
2700 | /* broadcast/multicast frame - no AP related processing */ | 2700 | /* broadcast/multicast frame - no AP related processing */ |
@@ -2821,10 +2821,10 @@ void hostap_handle_sta_release(void *ptr) | |||
2821 | void hostap_handle_sta_tx_exc(local_info_t *local, struct sk_buff *skb) | 2821 | void hostap_handle_sta_tx_exc(local_info_t *local, struct sk_buff *skb) |
2822 | { | 2822 | { |
2823 | struct sta_info *sta; | 2823 | struct sta_info *sta; |
2824 | struct ieee80211_hdr *hdr; | 2824 | struct ieee80211_hdr_4addr *hdr; |
2825 | struct hostap_skb_tx_data *meta; | 2825 | struct hostap_skb_tx_data *meta; |
2826 | 2826 | ||
2827 | hdr = (struct ieee80211_hdr *) skb->data; | 2827 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
2828 | meta = (struct hostap_skb_tx_data *) skb->cb; | 2828 | meta = (struct hostap_skb_tx_data *) skb->cb; |
2829 | 2829 | ||
2830 | spin_lock(&local->ap->sta_table_lock); | 2830 | spin_lock(&local->ap->sta_table_lock); |
@@ -2892,7 +2892,7 @@ static void hostap_update_sta_ps2(local_info_t *local, struct sta_info *sta, | |||
2892 | 2892 | ||
2893 | /* Called only as a tasklet (software IRQ). Called for each RX frame to update | 2893 | /* Called only as a tasklet (software IRQ). Called for each RX frame to update |
2894 | * STA power saving state. pwrmgt is a flag from 802.11 frame_ctl field. */ | 2894 | * STA power saving state. pwrmgt is a flag from 802.11 frame_ctl field. */ |
2895 | int hostap_update_sta_ps(local_info_t *local, struct ieee80211_hdr *hdr) | 2895 | int hostap_update_sta_ps(local_info_t *local, struct ieee80211_hdr_4addr *hdr) |
2896 | { | 2896 | { |
2897 | struct sta_info *sta; | 2897 | struct sta_info *sta; |
2898 | u16 fc; | 2898 | u16 fc; |
@@ -2925,12 +2925,12 @@ ap_rx_ret hostap_handle_sta_rx(local_info_t *local, struct net_device *dev, | |||
2925 | int ret; | 2925 | int ret; |
2926 | struct sta_info *sta; | 2926 | struct sta_info *sta; |
2927 | u16 fc, type, stype; | 2927 | u16 fc, type, stype; |
2928 | struct ieee80211_hdr *hdr; | 2928 | struct ieee80211_hdr_4addr *hdr; |
2929 | 2929 | ||
2930 | if (local->ap == NULL) | 2930 | if (local->ap == NULL) |
2931 | return AP_RX_CONTINUE; | 2931 | return AP_RX_CONTINUE; |
2932 | 2932 | ||
2933 | hdr = (struct ieee80211_hdr *) skb->data; | 2933 | hdr = (struct ieee80211_hdr_4addr *) skb->data; |
2934 | 2934 | ||
2935 | fc = le16_to_cpu(hdr->frame_ctl); | 2935 | fc = le16_to_cpu(hdr->frame_ctl); |
2936 | type = WLAN_FC_GET_TYPE(fc); | 2936 | type = WLAN_FC_GET_TYPE(fc); |
@@ -3058,7 +3058,7 @@ ap_rx_ret hostap_handle_sta_rx(local_info_t *local, struct net_device *dev, | |||
3058 | 3058 | ||
3059 | /* Called only as a tasklet (software IRQ) */ | 3059 | /* Called only as a tasklet (software IRQ) */ |
3060 | int hostap_handle_sta_crypto(local_info_t *local, | 3060 | int hostap_handle_sta_crypto(local_info_t *local, |
3061 | struct ieee80211_hdr *hdr, | 3061 | struct ieee80211_hdr_4addr *hdr, |
3062 | struct ieee80211_crypt_data **crypt, | 3062 | struct ieee80211_crypt_data **crypt, |
3063 | void **sta_ptr) | 3063 | void **sta_ptr) |
3064 | { | 3064 | { |
@@ -3160,7 +3160,7 @@ int hostap_add_sta(struct ap_data *ap, u8 *sta_addr) | |||
3160 | 3160 | ||
3161 | /* Called only as a tasklet (software IRQ) */ | 3161 | /* Called only as a tasklet (software IRQ) */ |
3162 | int hostap_update_rx_stats(struct ap_data *ap, | 3162 | int hostap_update_rx_stats(struct ap_data *ap, |
3163 | struct ieee80211_hdr *hdr, | 3163 | struct ieee80211_hdr_4addr *hdr, |
3164 | struct hostap_80211_rx_status *rx_stats) | 3164 | struct hostap_80211_rx_status *rx_stats) |
3165 | { | 3165 | { |
3166 | struct sta_info *sta; | 3166 | struct sta_info *sta; |
@@ -3174,7 +3174,7 @@ int hostap_update_rx_stats(struct ap_data *ap, | |||
3174 | sta->last_rx_silence = rx_stats->noise; | 3174 | sta->last_rx_silence = rx_stats->noise; |
3175 | sta->last_rx_signal = rx_stats->signal; | 3175 | sta->last_rx_signal = rx_stats->signal; |
3176 | sta->last_rx_rate = rx_stats->rate; | 3176 | sta->last_rx_rate = rx_stats->rate; |
3177 | sta->last_rx_updated = 7; | 3177 | sta->last_rx_updated = IW_QUAL_ALL_UPDATED | IW_QUAL_DBM; |
3178 | if (rx_stats->rate == 10) | 3178 | if (rx_stats->rate == 10) |
3179 | sta->rx_count[0]++; | 3179 | sta->rx_count[0]++; |
3180 | else if (rx_stats->rate == 20) | 3180 | else if (rx_stats->rate == 20) |