All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Nick Kossifidis" <mickflemm@gmail.com>
To: kvalo@codeaurora.org, ath9k-devel@qca.qualcomm.com
Cc: linux-wireless@vger.kernel.org, ath9k-devel@lists.ath9k.org,
	adrian.chadd@gmail.com, Nick Kossifidis <mickflemm@gmail.com>
Subject: [PATCH 00/11] ath9k: Spectral scan updates
Date: Wed, 29 Apr 2015 23:51:11 +0000	[thread overview]
Message-ID: <1430351482-59418-1-git-send-email-mickflemm@gmail.com> (raw)

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(-)

-- 
2.3.5


WARNING: multiple messages have this Message-ID (diff)
From: Nick Kossifidis <mickflemm@gmail.com>
To: ath9k-devel@lists.ath9k.org
Subject: [ath9k-devel] [PATCH 00/11] ath9k: Spectral scan updates
Date: Wed, 29 Apr 2015 23:51:11 +0000	[thread overview]
Message-ID: <1430351482-59418-1-git-send-email-mickflemm@gmail.com> (raw)

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(-)

-- 
2.3.5

             reply	other threads:[~2015-04-29 23:51 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-29 23:51 Nick Kossifidis [this message]
2015-04-29 23:51 ` [ath9k-devel] [PATCH 00/11] ath9k: Spectral scan updates Nick Kossifidis
2015-04-29 23:51 ` [PATCH 01/11] ath9k: Add a new debug flag for FFT spectral scan Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-05-09 13:47   ` [01/11] " Kalle Valo
2015-05-09 13:47     ` [ath9k-devel] " Kalle Valo
2015-04-29 23:51 ` [PATCH 02/11] ath9k: Fix hanlding of maximum magnitude index Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 03/11] ath9k: Move processing of FFT frames to different functions Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 04/11] ath9k: Perform integrity checks when processing FFT frames Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 05/11] ath9k: Support processing of multiple FFT frames per report Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 06/11] ath9k: Skip malformed frames on normal FFT report Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 07/11] ath9k: No need for that extra memcpy Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 8/11] ath9k: Skip FFT reports if we are out of output buffers Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 9/11] ath9k: No need for that extra memset Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 10/11] ath9k: Mix the received FFT bins to the random pool Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-04-29 23:51 ` [PATCH 11/11] ath9k: Enable short repeat by default on ath9k_htc Nick Kossifidis
2015-04-29 23:51   ` [ath9k-devel] " Nick Kossifidis
2015-05-01 12:46 ` [PATCH 00/11] ath9k: Spectral scan updates Bob Copeland
2015-05-01 12:46   ` [ath9k-devel] " Bob Copeland

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1430351482-59418-1-git-send-email-mickflemm@gmail.com \
    --to=mickflemm@gmail.com \
    --cc=adrian.chadd@gmail.com \
    --cc=ath9k-devel@lists.ath9k.org \
    --cc=ath9k-devel@qca.qualcomm.com \
    --cc=kvalo@codeaurora.org \
    --cc=linux-wireless@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.