Skip to content

ath9k: Spectral scan updates

Nick Kossifidis ath9k-devel linux-wireless 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest11 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/11ath9k: Add a new debug flag for FFT spectral scandrivers/net/wireless/ath/ath.h+2 -01 reply
2/11ath9k: Fix hanlding of maximum magnitude indexdrivers/net/wireless/ath/ath9k/common-spectral.c drivers/net/wireless/ath/ath9k/common-spectral.h+28 -100 replies
3/11ath9k: Move processing of FFT frames to different functionsdrivers/net/wireless/ath/ath9k/common-spectral.c drivers/net/wireless/ath/ath9k/common-spectral.h+171 -1110 replies
4/11ath9k: Perform integrity checks when processing FFT framesdrivers/net/wireless/ath/ath9k/common-spectral.c+163 -60 replies
5/11ath9k: Support processing of multiple FFT frames per report.drivers/net/wireless/ath/ath9k/common-spectral.c+237 -300 replies
6/11ath9k: Skip malformed frames on normal FFT reportdrivers/net/wireless/ath/ath9k/common-spectral.c+62 -320 replies
7/11ath9k: No need for that extra memcpydrivers/net/wireless/ath/ath9k/common-spectral.c+2 -40 replies
8/11ath9k: Skip FFT reports if we are out of output buffersdrivers/net/wireless/ath/ath9k/common-spectral.c+28 -00 replies
9/11ath9k: No need for that extra memsetdrivers/net/wireless/ath/ath9k/common-spectral.c+2 -10 replies
10/11ath9k: Mix the received FFT bins to the random pooldrivers/net/wireless/ath/ath9k/common-spectral.c+13 -10 replies
11/11ath9k: Enable short repeat by default on ath9k_htcdrivers/net/wireless/ath/ath9k/htc_drv_init.c+1 -10 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [ath9k-devel] [PATCH 00/11] ath9k: Spectral scan updates

On FFT spectral scans the hardware is able to send multiple FFT frames per report (packet).

This is the default behavior when short_repeat is set to 0 (when is set to 1 hw will only generate one frame per report since it only has 4usec to perform the measurement), however the current code doesn't support that. In case hardware sends multiple frames back the length check will fail and no frames will be processed. So the current code doesn't work unless short_repeat is set to 1 or if the hardware sends a single report per packet for some other reason. Notice that on ath9k_htc short_repeat is by default set to 0 so that's what happened on my experiments with an AR7010 + AR9280 device, I got lots of data back but no output on the spectral scan.

This patch series adds support for handling multiple FFT frames per report, performs a few integrity checks on the received data and in general improves the handling of FFT spectral scans.

Note that this feature generates a LOT of data, each report can be up to 1K for HT20 and 2K+ for HT20/40. It's meant to be used for real-time data processing in the userspace. The buffers we currently have for relayfs won't be able to handle a full report unless they are being consumed from the userspace fast enough. That's why this feature is disabled by default (short_repeat is set to 1 by default also on ath9k_htc).

Now we need someone to write a nice real-time GUI for that...

Many thanks to Adrian Chadd for adding support for FFT spectral scans in the first place !

Hope you enjoy it ;-)

Nick Kossifidis (11):
Add a new debug flag for FFT spectral scan Fix hanlding of maximum magnitude index
Move processing of FFT frames to different functions Perform integrity checks when processing FFT frames Support processing of multiple FFT frames per report Skip malformed frames on normal FFT report No need for that extra memcpy
Skip FFT reports if we are out of output buffers No need for that extra memset
Mix the received FFT bins to the random pool Enable short repeat by default on ath9k_htc

 drivers/net/wireless/ath/ath.h                   |   2 +
 drivers/net/wireless/ath/ath9k/common-spectral.c | 740 +++++++++++++++++++----
 drivers/net/wireless/ath/ath9k/common-spectral.h |  35 +-
 drivers/net/wireless/ath/ath9k/htc_drv_init.c    |   2 +-
 4 files changed, 646 insertions(+), 133 deletions(-)
Signature · 1 line
2.3.5