diff options
Diffstat (limited to 'drivers/net/wireless/rtlwifi/usb.c')
-rw-r--r-- | drivers/net/wireless/rtlwifi/usb.c | 19 |
1 files changed, 15 insertions, 4 deletions
diff --git a/drivers/net/wireless/rtlwifi/usb.c b/drivers/net/wireless/rtlwifi/usb.c index f5d85735d64..a9367eba1ea 100644 --- a/drivers/net/wireless/rtlwifi/usb.c +++ b/drivers/net/wireless/rtlwifi/usb.c | |||
@@ -852,6 +852,7 @@ static void _rtl_usb_tx_preprocess(struct ieee80211_hw *hw, struct sk_buff *skb, | |||
852 | struct rtl_mac *mac = rtl_mac(rtl_priv(hw)); | 852 | struct rtl_mac *mac = rtl_mac(rtl_priv(hw)); |
853 | struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); | 853 | struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb); |
854 | struct rtl_tx_desc *pdesc = NULL; | 854 | struct rtl_tx_desc *pdesc = NULL; |
855 | struct rtl_tcb_desc tcb_desc; | ||
855 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)(skb->data); | 856 | struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)(skb->data); |
856 | __le16 fc = hdr->frame_control; | 857 | __le16 fc = hdr->frame_control; |
857 | u8 *pda_addr = hdr->addr1; | 858 | u8 *pda_addr = hdr->addr1; |
@@ -860,8 +861,17 @@ static void _rtl_usb_tx_preprocess(struct ieee80211_hw *hw, struct sk_buff *skb, | |||
860 | u8 tid = 0; | 861 | u8 tid = 0; |
861 | u16 seq_number = 0; | 862 | u16 seq_number = 0; |
862 | 863 | ||
863 | if (ieee80211_is_mgmt(fc)) | 864 | if (ieee80211_is_auth(fc)) { |
864 | rtl_tx_mgmt_proc(hw, skb); | 865 | RT_TRACE(rtlpriv, COMP_SEND, DBG_DMESG, ("MAC80211_LINKING\n")); |
866 | rtl_ips_nic_on(hw); | ||
867 | } | ||
868 | |||
869 | if (rtlpriv->psc.sw_ps_enabled) { | ||
870 | if (ieee80211_is_data(fc) && !ieee80211_is_nullfunc(fc) && | ||
871 | !ieee80211_has_pm(fc)) | ||
872 | hdr->frame_control |= cpu_to_le16(IEEE80211_FCTL_PM); | ||
873 | } | ||
874 | |||
865 | rtl_action_proc(hw, skb, true); | 875 | rtl_action_proc(hw, skb, true); |
866 | if (is_multicast_ether_addr(pda_addr)) | 876 | if (is_multicast_ether_addr(pda_addr)) |
867 | rtlpriv->stats.txbytesmulticast += skb->len; | 877 | rtlpriv->stats.txbytesmulticast += skb->len; |
@@ -878,7 +888,7 @@ static void _rtl_usb_tx_preprocess(struct ieee80211_hw *hw, struct sk_buff *skb, | |||
878 | seq_number <<= 4; | 888 | seq_number <<= 4; |
879 | } | 889 | } |
880 | rtlpriv->cfg->ops->fill_tx_desc(hw, hdr, (u8 *)pdesc, info, skb, | 890 | rtlpriv->cfg->ops->fill_tx_desc(hw, hdr, (u8 *)pdesc, info, skb, |
881 | hw_queue); | 891 | hw_queue, &tcb_desc); |
882 | if (!ieee80211_has_morefrags(hdr->frame_control)) { | 892 | if (!ieee80211_has_morefrags(hdr->frame_control)) { |
883 | if (qc) | 893 | if (qc) |
884 | mac->tids[tid].seq_number = seq_number; | 894 | mac->tids[tid].seq_number = seq_number; |
@@ -887,7 +897,8 @@ static void _rtl_usb_tx_preprocess(struct ieee80211_hw *hw, struct sk_buff *skb, | |||
887 | rtlpriv->cfg->ops->led_control(hw, LED_CTL_TX); | 897 | rtlpriv->cfg->ops->led_control(hw, LED_CTL_TX); |
888 | } | 898 | } |
889 | 899 | ||
890 | static int rtl_usb_tx(struct ieee80211_hw *hw, struct sk_buff *skb) | 900 | static int rtl_usb_tx(struct ieee80211_hw *hw, struct sk_buff *skb, |
901 | struct rtl_tcb_desc *dummy) | ||
891 | { | 902 | { |
892 | struct rtl_usb *rtlusb = rtl_usbdev(rtl_usbpriv(hw)); | 903 | struct rtl_usb *rtlusb = rtl_usbdev(rtl_usbpriv(hw)); |
893 | struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw)); | 904 | struct rtl_hal *rtlhal = rtl_hal(rtl_priv(hw)); |