diff options
author | Chaoming_Li <chaoming_li@realsil.com.cn> | 2011-04-25 13:53:29 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-04-26 16:13:32 -0400 |
commit | d93cdee975bc6894b0a7c3f3eb4f2b34303163f8 (patch) | |
tree | 79cbfe0e7a84d9de4dd0902829809c1f53aa03bb /drivers/net/wireless/rtlwifi | |
parent | 81b290451122e93b9731bc333c6be2e49fa5bc0c (diff) |
rtlwifi: Convert usb routines for addition of rtl8192se and rtl8192de
Convert usb routines for addition of RTL8192SE and RTL8192DE code
Signed-off-by: Chaoming_Li <chaoming_li@realsil.com.cn>
Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rtlwifi')
-rw-r--r-- | drivers/net/wireless/rtlwifi/pci.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/rtlwifi/usb.c | 14 | ||||
-rw-r--r-- | drivers/net/wireless/rtlwifi/wifi.h | 7 |
3 files changed, 13 insertions, 10 deletions
diff --git a/drivers/net/wireless/rtlwifi/pci.c b/drivers/net/wireless/rtlwifi/pci.c index fa66205d8b95..e496361fa2c6 100644 --- a/drivers/net/wireless/rtlwifi/pci.c +++ b/drivers/net/wireless/rtlwifi/pci.c | |||
@@ -1569,10 +1569,8 @@ int rtl_pci_tx(struct ieee80211_hw *hw, struct sk_buff *skb, | |||
1569 | if (ieee80211_is_data(fc)) | 1569 | if (ieee80211_is_data(fc)) |
1570 | rtlpriv->cfg->ops->led_control(hw, LED_CTL_TX); | 1570 | rtlpriv->cfg->ops->led_control(hw, LED_CTL_TX); |
1571 | 1571 | ||
1572 | #if 0 /* temporary */ | ||
1573 | rtlpriv->cfg->ops->fill_tx_desc(hw, hdr, (u8 *)pdesc, | 1572 | rtlpriv->cfg->ops->fill_tx_desc(hw, hdr, (u8 *)pdesc, |
1574 | info, skb, hw_queue, ptcb_desc); | 1573 | info, skb, hw_queue, ptcb_desc); |
1575 | #endif | ||
1576 | 1574 | ||
1577 | __skb_queue_tail(&ring->queue, skb); | 1575 | __skb_queue_tail(&ring->queue, skb); |
1578 | 1576 | ||
diff --git a/drivers/net/wireless/rtlwifi/usb.c b/drivers/net/wireless/rtlwifi/usb.c index 14539eb9589e..a9367eba1ea7 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,6 +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 | ||
864 | if (ieee80211_is_auth(fc)) { | ||
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 | |||
863 | rtl_action_proc(hw, skb, true); | 875 | rtl_action_proc(hw, skb, true); |
864 | if (is_multicast_ether_addr(pda_addr)) | 876 | if (is_multicast_ether_addr(pda_addr)) |
865 | rtlpriv->stats.txbytesmulticast += skb->len; | 877 | rtlpriv->stats.txbytesmulticast += skb->len; |
@@ -876,7 +888,7 @@ static void _rtl_usb_tx_preprocess(struct ieee80211_hw *hw, struct sk_buff *skb, | |||
876 | seq_number <<= 4; | 888 | seq_number <<= 4; |
877 | } | 889 | } |
878 | 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, |
879 | hw_queue); | 891 | hw_queue, &tcb_desc); |
880 | if (!ieee80211_has_morefrags(hdr->frame_control)) { | 892 | if (!ieee80211_has_morefrags(hdr->frame_control)) { |
881 | if (qc) | 893 | if (qc) |
882 | mac->tids[tid].seq_number = seq_number; | 894 | mac->tids[tid].seq_number = seq_number; |
diff --git a/drivers/net/wireless/rtlwifi/wifi.h b/drivers/net/wireless/rtlwifi/wifi.h index 4776cd1ee4f8..683f7f71b6cd 100644 --- a/drivers/net/wireless/rtlwifi/wifi.h +++ b/drivers/net/wireless/rtlwifi/wifi.h | |||
@@ -1378,18 +1378,11 @@ struct rtl_hal_ops { | |||
1378 | void (*update_rate_table) (struct ieee80211_hw *hw); | 1378 | void (*update_rate_table) (struct ieee80211_hw *hw); |
1379 | #endif | 1379 | #endif |
1380 | void (*update_rate_mask) (struct ieee80211_hw *hw, u8 rssi_level); | 1380 | void (*update_rate_mask) (struct ieee80211_hw *hw, u8 rssi_level); |
1381 | #if 0 /* temporary */ | ||
1382 | void (*fill_tx_desc) (struct ieee80211_hw *hw, | 1381 | void (*fill_tx_desc) (struct ieee80211_hw *hw, |
1383 | struct ieee80211_hdr *hdr, u8 *pdesc_tx, | 1382 | struct ieee80211_hdr *hdr, u8 *pdesc_tx, |
1384 | struct ieee80211_tx_info *info, | 1383 | struct ieee80211_tx_info *info, |
1385 | struct sk_buff *skb, u8 hw_queue, | 1384 | struct sk_buff *skb, u8 hw_queue, |
1386 | struct rtl_tcb_desc *ptcb_desc); | 1385 | struct rtl_tcb_desc *ptcb_desc); |
1387 | #else | ||
1388 | void (*fill_tx_desc) (struct ieee80211_hw *hw, | ||
1389 | struct ieee80211_hdr *hdr, u8 *pdesc_tx, | ||
1390 | struct ieee80211_tx_info *info, | ||
1391 | struct sk_buff *skb, unsigned int queue_index); | ||
1392 | #endif | ||
1393 | void (*fill_fake_txdesc) (struct ieee80211_hw *hw, u8 *pDesc, | 1386 | void (*fill_fake_txdesc) (struct ieee80211_hw *hw, u8 *pDesc, |
1394 | u32 buffer_len, bool bIsPsPoll); | 1387 | u32 buffer_len, bool bIsPsPoll); |
1395 | void (*fill_tx_cmddesc) (struct ieee80211_hw *hw, u8 *pdesc, | 1388 | void (*fill_tx_cmddesc) (struct ieee80211_hw *hw, u8 *pdesc, |