diff options
author | Daniel C Halperin <daniel.c.halperin@intel.com> | 2009-08-21 16:34:21 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-08-28 14:40:38 -0400 |
commit | c5f8cdb72e3940d647980358dec0aba945a3bb57 (patch) | |
tree | 27003369d32a9bcab0148d854c16a47e1320e1ad /drivers/net/wireless/iwlwifi | |
parent | 7ebaeff8ae0ba14c086b117f451c5b40bea8a64b (diff) |
iwlwifi: set HT flags in ieee80211_rx_status for received packets
Add code to set the HT flags (HT, 40 MHz, Short guard interval) in
the ieee80211_rx_status field passed to mac80211. This ensures that mac80211
processes these HT packets correctly.
Signed-off-by: Daniel C Halperin <daniel.c.halperin@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-rx.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-rx.c b/drivers/net/wireless/iwlwifi/iwl-rx.c index 353d9a2ddbca..e34d3fcb6c3d 100644 --- a/drivers/net/wireless/iwlwifi/iwl-rx.c +++ b/drivers/net/wireless/iwlwifi/iwl-rx.c | |||
@@ -915,6 +915,7 @@ void iwl_rx_reply_rx(struct iwl_priv *priv, | |||
915 | u32 len; | 915 | u32 len; |
916 | u32 ampdu_status; | 916 | u32 ampdu_status; |
917 | u16 fc; | 917 | u16 fc; |
918 | u32 rate_n_flags; | ||
918 | 919 | ||
919 | /** | 920 | /** |
920 | * REPLY_RX and REPLY_RX_MPDU_CMD are handled differently. | 921 | * REPLY_RX and REPLY_RX_MPDU_CMD are handled differently. |
@@ -1032,6 +1033,15 @@ void iwl_rx_reply_rx(struct iwl_priv *priv, | |||
1032 | if (phy_res->phy_flags & RX_RES_PHY_FLAGS_SHORT_PREAMBLE_MSK) | 1033 | if (phy_res->phy_flags & RX_RES_PHY_FLAGS_SHORT_PREAMBLE_MSK) |
1033 | rx_status.flag |= RX_FLAG_SHORTPRE; | 1034 | rx_status.flag |= RX_FLAG_SHORTPRE; |
1034 | 1035 | ||
1036 | /* Set up the HT phy flags */ | ||
1037 | rate_n_flags = le32_to_cpu(phy_res->rate_n_flags); | ||
1038 | if (rate_n_flags & RATE_MCS_HT_MSK) | ||
1039 | rx_status.flag |= RX_FLAG_HT; | ||
1040 | if (rate_n_flags & RATE_MCS_HT40_MSK) | ||
1041 | rx_status.flag |= RX_FLAG_40MHZ; | ||
1042 | if (rate_n_flags & RATE_MCS_SGI_MSK) | ||
1043 | rx_status.flag |= RX_FLAG_SHORT_GI; | ||
1044 | |||
1035 | if (iwl_is_network_packet(priv, header)) { | 1045 | if (iwl_is_network_packet(priv, header)) { |
1036 | priv->last_rx_rssi = rx_status.signal; | 1046 | priv->last_rx_rssi = rx_status.signal; |
1037 | priv->last_beacon_time = priv->ucode_beacon_time; | 1047 | priv->last_beacon_time = priv->ucode_beacon_time; |