1
0

020-16-rt2800-use-TXOP_BACKOFF-for-probe-frames.patch 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. From fb47ada8dc3c30c8e7b415da155742b49536c61e Mon Sep 17 00:00:00 2001
  2. From: Stanislaw Gruszka <sgruszka@redhat.com>
  3. Date: Wed, 15 Feb 2017 10:25:12 +0100
  4. Subject: [PATCH 16/19] rt2800: use TXOP_BACKOFF for probe frames
  5. Even if we do not set AMPDU bit in TXWI, device still can aggregate
  6. frame and send it with rate not corresponding to requested. That mean
  7. we can do not sent probe frames with requested rate. To prevent that
  8. use TXOP_BACKOFF for probe frames.
  9. Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
  10. Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
  11. ---
  12. drivers/net/wireless/ralink/rt2x00/rt2x00queue.c | 7 ++++---
  13. 1 file changed, 4 insertions(+), 3 deletions(-)
  14. diff --git a/drivers/net/wireless/ralink/rt2x00/rt2x00queue.c b/drivers/net/wireless/ralink/rt2x00/rt2x00queue.c
  15. index e1660b92b20c..a2c1ca5c76d1 100644
  16. --- a/drivers/net/wireless/ralink/rt2x00/rt2x00queue.c
  17. +++ b/drivers/net/wireless/ralink/rt2x00/rt2x00queue.c
  18. @@ -372,15 +372,16 @@ static void rt2x00queue_create_tx_descriptor_ht(struct rt2x00_dev *rt2x00dev,
  19. /*
  20. * Determine IFS values
  21. - * - Use TXOP_BACKOFF for management frames except beacons
  22. + * - Use TXOP_BACKOFF for probe and management frames except beacons
  23. * - Use TXOP_SIFS for fragment bursts
  24. * - Use TXOP_HTTXOP for everything else
  25. *
  26. * Note: rt2800 devices won't use CTS protection (if used)
  27. * for frames not transmitted with TXOP_HTTXOP
  28. */
  29. - if (ieee80211_is_mgmt(hdr->frame_control) &&
  30. - !ieee80211_is_beacon(hdr->frame_control))
  31. + if ((ieee80211_is_mgmt(hdr->frame_control) &&
  32. + !ieee80211_is_beacon(hdr->frame_control)) ||
  33. + (tx_info->flags & IEEE80211_TX_CTL_RATE_CTRL_PROBE))
  34. txdesc->u.ht.txop = TXOP_BACKOFF;
  35. else if (!(tx_info->flags & IEEE80211_TX_CTL_FIRST_FRAGMENT))
  36. txdesc->u.ht.txop = TXOP_SIFS;
  37. --
  38. 2.12.1