* [PATCH] mac80211_hwsim: Fix RX status reporting for HT
@ 2011-08-06 20:07 Jouni Malinen
2011-08-08 8:33 ` Johannes Berg
0 siblings, 1 reply; 3+ messages in thread
From: Jouni Malinen @ 2011-08-06 20:07 UTC (permalink / raw)
To: John W. Linville; +Cc: linux-wireless
RX_FLAG_HT must be included when reporting MCS rates. Without
this, mac80211 ended up dropping any frame sent at MCS index 12
or higher and that resulted in oddly random looking errors in
mac80211_hwsim tests.
Signed-off-by: Jouni Malinen <j@w1.fi>
---
drivers/net/wireless/mac80211_hwsim.c | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/drivers/net/wireless/mac80211_hwsim.c b/drivers/net/wireless/mac80211_hwsim.c
index 031cd89..34b79fc 100644
--- a/drivers/net/wireless/mac80211_hwsim.c
+++ b/drivers/net/wireless/mac80211_hwsim.c
@@ -612,6 +612,12 @@ static bool mac80211_hwsim_tx_frame_no_nl(struct ieee80211_hw *hw,
rx_status.freq = data->channel->center_freq;
rx_status.band = data->channel->band;
rx_status.rate_idx = info->control.rates[0].idx;
+ if (info->control.rates[0].flags & IEEE80211_TX_RC_MCS)
+ rx_status.flag |= RX_FLAG_HT;
+ if (info->control.rates[0].flags & IEEE80211_TX_RC_40_MHZ_WIDTH)
+ rx_status.flag |= RX_FLAG_40MHZ;
+ if (info->control.rates[0].flags & IEEE80211_TX_RC_SHORT_GI)
+ rx_status.flag |= RX_FLAG_SHORT_GI;
/* TODO: simulate real signal strength (and optional packet loss) */
rx_status.signal = data->power_level - 50;
--
1.7.4.1
--
Jouni Malinen PGP id EFC895FA
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] mac80211_hwsim: Fix RX status reporting for HT
2011-08-06 20:07 [PATCH] mac80211_hwsim: Fix RX status reporting for HT Jouni Malinen
@ 2011-08-08 8:33 ` Johannes Berg
2011-08-08 9:00 ` Jouni Malinen
0 siblings, 1 reply; 3+ messages in thread
From: Johannes Berg @ 2011-08-08 8:33 UTC (permalink / raw)
To: Jouni Malinen; +Cc: John W. Linville, linux-wireless
On Sat, 2011-08-06 at 23:07 +0300, Jouni Malinen wrote:
> RX_FLAG_HT must be included when reporting MCS rates. Without
> this, mac80211 ended up dropping any frame sent at MCS index 12
> or higher and that resulted in oddly random looking errors in
> mac80211_hwsim tests.
This "solved" the timing thing you ran into with the unrelated
suspend/resume patch then I guess?
johannes
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] mac80211_hwsim: Fix RX status reporting for HT
2011-08-08 8:33 ` Johannes Berg
@ 2011-08-08 9:00 ` Jouni Malinen
0 siblings, 0 replies; 3+ messages in thread
From: Jouni Malinen @ 2011-08-08 9:00 UTC (permalink / raw)
To: Johannes Berg; +Cc: John W. Linville, linux-wireless
On Mon, Aug 08, 2011 at 10:33:08AM +0200, Johannes Berg wrote:
> On Sat, 2011-08-06 at 23:07 +0300, Jouni Malinen wrote:
> > RX_FLAG_HT must be included when reporting MCS rates. Without
> > this, mac80211 ended up dropping any frame sent at MCS index 12
> > or higher and that resulted in oddly random looking errors in
> > mac80211_hwsim tests.
>
> This "solved" the timing thing you ran into with the unrelated
> suspend/resume patch then I guess?
Yes, it did. This was indeed the reason for semi-random dropping of
EAPOL frames and the randomness part made it difficult to figure out
what on earth was happening.
--
Jouni Malinen PGP id EFC895FA
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-08-08 9:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-06 20:07 [PATCH] mac80211_hwsim: Fix RX status reporting for HT Jouni Malinen
2011-08-08 8:33 ` Johannes Berg
2011-08-08 9:00 ` Jouni Malinen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).