Skip to content

Commit

Permalink
mac80211: Remove radiotap rate-present flag for HT
Browse files Browse the repository at this point in the history
Since we do not currently report HT rates (MCS index) in radiotap
header for HT rates, we should not claim the rate is present. The rate
octet itself is used as padding in this case, so only the it_present
flag needs to be removed in case of HT rates.

Signed-off-by: Jouni Malinen <jouni.malinen@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Jouni Malinen authored and John W. Linville committed Dec 19, 2008
1 parent d858822 commit 8d6f658
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions net/mac80211/rx.c
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@ ieee80211_add_rx_radiotap_header(struct ieee80211_local *local,
/* radiotap header, set always present flags */
rthdr->it_present =
cpu_to_le32((1 << IEEE80211_RADIOTAP_FLAGS) |
(1 << IEEE80211_RADIOTAP_RATE) |
(1 << IEEE80211_RADIOTAP_CHANNEL) |
(1 << IEEE80211_RADIOTAP_ANTENNA) |
(1 << IEEE80211_RADIOTAP_RX_FLAGS));
Expand Down Expand Up @@ -158,8 +157,10 @@ ieee80211_add_rx_radiotap_header(struct ieee80211_local *local,
* - short-GI (status->flag & RX_FLAG_SHORT_GI)
*/
*pos = 0;
} else
} else {
rthdr->it_present |= (1 << IEEE80211_RADIOTAP_RATE);
*pos = rate->bitrate / 5;
}
pos++;

/* IEEE80211_RADIOTAP_CHANNEL */
Expand Down

0 comments on commit 8d6f658

Please sign in to comment.