On Thu, May 22, 2008 at 8:34 PM, Johannes Berg <johannes@xxxxxxxxxxxxxxxx> wrote: >> >> This does not work, since we use injection for other types of >> >> frames. For example management frames from hostapd. We don't want >> >> (and can't) make hostapd keep track of sequence numbers. >> >> You'll have to contact radiotap people and add a flag for this. >> >> This would also solve the hardware counter problem then. > >> The flag is IEEE80211_TX_INJECTED. Here is a new patch, for the >> current wireless-testing: > > Reorder the two blocks and you have your answer. NO. > > johannes > Hmm, shouldn't this version fix the hostap and other non-monitor-mode cases? --- diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c index 1a3b50b..1fb4f92 100644 --- a/net/mac80211/tx.c +++ b/net/mac80211/tx.c @@ -292,6 +292,11 @@ ieee80211_tx_h_sequence(struct ieee80211_tx_data *tx) { struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)tx->skb->data; + /* Monitor mode injectors handle sequence numbers themselves */ + if (unlikely(tx->flags & IEEE80211_TX_INJECTED) && + tx->sdata->vif.type == IEEE80211_IF_TYPE_MNTR) + return TX_CONTINUE; + if (ieee80211_get_hdrlen(le16_to_cpu(hdr->frame_control)) >= 24) ieee80211_include_sequence(tx->sdata, hdr); -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html