add kernel packages for the ixp4xx-beeper and appletalk -- closes #6618
[openwrt.git] / package / mac80211 / patches / 550-radiotap_ps_buffer.patch
1 --- a/include/net/mac80211.h
2 +++ b/include/net/mac80211.h
3 @@ -274,6 +274,8 @@ struct ieee80211_bss_conf {
4   * @IEEE80211_TX_INTFL_RETRANSMISSION: This frame is being retransmitted
5   *     after TX status because the destination was asleep, it must not
6   *     be modified again (no seqno assignment, crypto, etc.)
7 + * @IEEE80211_TX_INTFL_HAS_RADIOTAP: This frame was injected and still
8 + *     has a radiotap header at skb->data.
9   */
10  enum mac80211_tx_control_flags {
11         IEEE80211_TX_CTL_REQ_TX_STATUS          = BIT(0),
12 @@ -295,6 +297,7 @@ enum mac80211_tx_control_flags {
13         IEEE80211_TX_CTL_PSPOLL_RESPONSE        = BIT(17),
14         IEEE80211_TX_CTL_MORE_FRAMES            = BIT(18),
15         IEEE80211_TX_INTFL_RETRANSMISSION       = BIT(19),
16 +       IEEE80211_TX_INTFL_HAS_RADIOTAP         = BIT(20),
17  };
18  
19  /**
20 --- a/net/mac80211/tx.c
21 +++ b/net/mac80211/tx.c
22 @@ -1110,7 +1110,7 @@ ieee80211_tx_prepare(struct ieee80211_su
23         tx->flags |= IEEE80211_TX_FRAGMENTED;
24  
25         /* process and remove the injection radiotap header */
26 -       if (unlikely(info->flags & IEEE80211_TX_CTL_INJECTED)) {
27 +       if (unlikely(info->flags & IEEE80211_TX_INTFL_HAS_RADIOTAP)) {
28                 if (!__ieee80211_parse_tx_radiotap(tx, skb))
29                         return TX_DROP;
30  
31 @@ -1119,6 +1119,7 @@ ieee80211_tx_prepare(struct ieee80211_su
32                  * the radiotap header that was present and pre-filled
33                  * 'tx' with tx control information.
34                  */
35 +               info->flags &= ~IEEE80211_TX_INTFL_HAS_RADIOTAP;
36         }
37  
38         /*
39 @@ -1501,7 +1502,8 @@ static void ieee80211_xmit(struct ieee80
40                 int hdrlen;
41                 u16 len_rthdr;
42  
43 -               info->flags |= IEEE80211_TX_CTL_INJECTED;
44 +               info->flags |= IEEE80211_TX_CTL_INJECTED |
45 +                              IEEE80211_TX_INTFL_HAS_RADIOTAP;
46  
47                 len_rthdr = ieee80211_get_radiotap_len(skb->data);
48                 hdr = (struct ieee80211_hdr *)(skb->data + len_rthdr);