Search Linux Wireless

Re: [PATCH] mac80211: do not alter injected seq numbers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, May 22, 2008 at 7:48 PM, JMF <tolas_feup@xxxxxxxxxxx> wrote:
> Michael Buesch <mb@...> writes:
>  (...)
>> > +   if (unlikely(tx->flags & IEEE80211_TXRXD_TX_INJECTED))
>> > +           return TXRX_CONTINUE;
>  (...)
>> 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 last time I saw tx.c, this should now be something like
>     info->flags & IEEE80211_TX_CTL_INJECTED
> But as far as I can see the usage is the same.
> And, unless I'm wrong, IEEE80211_TX_CTL_INJECTED is only used
>  with Monitor mode interfaces.
> Does hostapd use monitor mode interfaces? Because if it doesn't,
>  and if I saw things correcly, info->flags won't be set to
>  IEEE80211_TX_CTL_INJECTED, right?
>
> Any comments on this?

The flag is IEEE80211_TX_INJECTED. Here is a new patch, for the
current wireless-testing:

Signed-off-by: Alejandro Grijalba Martínez <sud@xxxxxxxxxxxx>
Signed-off-by: Gábor Stefanik <netrolller.3d@xxxxxxxxx>

---

diff --git a/net/mac80211/tx.c b/net/mac80211/tx.c
index f35eaea..e5e8483 100644
--- a/net/mac80211/tx.c
+++ b/net/mac80211/tx.c
@@ -292,6 +292,9 @@ ieee80211_tx_h_sequence(struct ieee80211_tx_data *tx)
 {
       struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)tx->skb->data;

+       if (unlikely(tx->flags & IEEE80211_TX_INJECTED))
+               return TX_CONTINUE;
+
       if (ieee80211_get_hdrlen(le16_to_cpu(hdr->frame_control)) >= 24)
               ieee80211_include_sequence(tx->sdata, hdr);



-- 
Vista: [V]iruses, [I]ntruders, [S]pyware, [T]rojans and [A]dware. :-)
--
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

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux