318-v4.17-mac80211-round-IEEE80211_TX_STATUS_HEADROOM-up-to-mu.patch 923 B

1234567891011121314151617181920212223242526
  1. From: Felix Fietkau <[email protected]>
  2. Date: Fri, 9 Feb 2018 19:46:54 +0100
  3. Subject: [PATCH] mac80211: round IEEE80211_TX_STATUS_HEADROOM up to multiple
  4. of 4
  5. This ensures that mac80211 allocated management frames are properly
  6. aligned, which makes copying them more efficient.
  7. For instance, mt76 uses iowrite32_copy to copy beacon frames to beacon
  8. template memory on the chip.
  9. Misaligned 32-bit accesses cause CPU exceptions on MIPS and should be
  10. avoided.
  11. Signed-off-by: Felix Fietkau <[email protected]>
  12. ---
  13. --- a/include/net/mac80211.h
  14. +++ b/include/net/mac80211.h
  15. @@ -4145,7 +4145,7 @@ void ieee80211_sta_uapsd_trigger(struct
  16. * The TX headroom reserved by mac80211 for its own tx_status functions.
  17. * This is enough for the radiotap header.
  18. */
  19. -#define IEEE80211_TX_STATUS_HEADROOM 14
  20. +#define IEEE80211_TX_STATUS_HEADROOM ALIGN(14, 4)
  21. /**
  22. * ieee80211_sta_set_buffered - inform mac80211 about driver-buffered frames