319-v4.17-0004-mac80211-support-station-4-addr-mode-fast-rx.patch 1013 B

12345678910111213141516171819202122232425262728293031323334
  1. From: Felix Fietkau <[email protected]>
  2. Date: Fri, 23 Feb 2018 10:05:08 +0100
  3. Subject: [PATCH] mac80211: support station 4-addr mode fast-rx
  4. Signed-off-by: Felix Fietkau <[email protected]>
  5. ---
  6. --- a/net/mac80211/rx.c
  7. +++ b/net/mac80211/rx.c
  8. @@ -3738,10 +3738,6 @@ void ieee80211_check_fast_rx(struct sta_
  9. switch (sdata->vif.type) {
  10. case NL80211_IFTYPE_STATION:
  11. - /* 4-addr is harder to deal with, later maybe */
  12. - if (sdata->u.mgd.use_4addr)
  13. - goto clear;
  14. -
  15. if (sta->sta.tdls) {
  16. fastrx.da_offs = offsetof(struct ieee80211_hdr, addr1);
  17. fastrx.sa_offs = offsetof(struct ieee80211_hdr, addr2);
  18. @@ -3754,6 +3750,13 @@ void ieee80211_check_fast_rx(struct sta_
  19. cpu_to_le16(IEEE80211_FCTL_FROMDS);
  20. }
  21. + if (sdata->u.mgd.use_4addr && !sta->sta.tdls) {
  22. + fastrx.expected_ds_bits |=
  23. + cpu_to_le16(IEEE80211_FCTL_TODS);
  24. + fastrx.da_offs = offsetof(struct ieee80211_hdr, addr3);
  25. + fastrx.sa_offs = offsetof(struct ieee80211_hdr, addr4);
  26. + }
  27. +
  28. if (!sdata->u.mgd.powersave)
  29. break;