linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kalle Valo <kvalo@codeaurora.org>
To: Jouni Malinen <jouni@codeaurora.org>
Cc: ath11k@lists.infradead.org, linux-wireless@vger.kernel.org,
	Karthikeyan Periyasamy <periyasa@codeaurora.org>
Subject: Re: [PATCH 1/4] ath11k: Refactor spectral FFT bin size
Date: Fri, 24 Sep 2021 17:35:07 +0300	[thread overview]
Message-ID: <87ee9erqhw.fsf@codeaurora.org> (raw)
In-Reply-To: <20210721180809.90960-2-jouni@codeaurora.org> (Jouni Malinen's message of "Wed, 21 Jul 2021 21:08:06 +0300")

Jouni Malinen <jouni@codeaurora.org> writes:

> From: Karthikeyan Periyasamy <periyasa@codeaurora.org>
>
> In IPQ8074, actual FFT bin size is two bytes but hardware reports it
> with extra pad size of two bytes for each FFT bin. So finally each FFT
> bin advertise as four bytes size in the collected data. This FFT pad is
> not advertised in IPQ6018 platform. To accommodate this different
> behavior across the platforms, introduce the hw param fft_pad_sz and use
> it in spectral process. Also group all the spectral params under the new
> structure in hw param structure for scalable in future.
>
> Tested-on: IPQ8074 hw2.0 AHB WLAN.HK.2.4.0.1-01492-QCAHKSWPL_SILICONZ-1
> Tested-on: IPQ6018 hw1.0 AHB WLAN.HK.2.4.0.1-00330-QCAHKSWPL_SILICONZ-1
>
> Signed-off-by: Karthikeyan Periyasamy <periyasa@codeaurora.org>
> Signed-off-by: Jouni Malinen <jouni@codeaurora.org>
> ---
>  drivers/net/wireless/ath/ath11k/core.c     | 27 +++++++++++++++-------
>  drivers/net/wireless/ath/ath11k/hw.h       |  6 ++++-
>  drivers/net/wireless/ath/ath11k/spectral.c | 13 +++++------
>  3 files changed, 30 insertions(+), 16 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath11k/core.c b/drivers/net/wireless/ath/ath11k/core.c
> index 3179495cb3c9..2a81a544b6a9 100644
> --- a/drivers/net/wireless/ath/ath11k/core.c
> +++ b/drivers/net/wireless/ath/ath11k/core.c
> @@ -59,8 +59,13 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
>  		.vdev_start_delay = false,
>  		.htt_peer_map_v2 = true,
>  		.tcl_0_only = false,
> -		.spectral_fft_sz = 2,
> -
> +		.spectral = {
> +			.fft_sz = 2,
> +			/* HW bug, expected BIN size is 2 bytes but HW report as 4 bytes.
> +			 * so added pad size as 2 bytes to compensate the BIN size
> +			 */
> +			.fft_pad_sz = 2,
> +		},
>  		.interface_modes = BIT(NL80211_IFTYPE_STATION) |
>  					BIT(NL80211_IFTYPE_AP) |
>  					BIT(NL80211_IFTYPE_MESH_POINT),
> @@ -101,8 +106,10 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
>  		.vdev_start_delay = false,
>  		.htt_peer_map_v2 = true,
>  		.tcl_0_only = false,
> -		.spectral_fft_sz = 4,
> -
> +		.spectral = {
> +			.fft_sz = 4,
> +			.fft_pad_sz = 0,
> +		},
>  		.interface_modes = BIT(NL80211_IFTYPE_STATION) |
>  					BIT(NL80211_IFTYPE_AP) |
>  					BIT(NL80211_IFTYPE_MESH_POINT),
> @@ -143,8 +150,10 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
>  		.vdev_start_delay = true,
>  		.htt_peer_map_v2 = false,
>  		.tcl_0_only = true,
> -		.spectral_fft_sz = 0,
> -
> +		.spectral = {
> +			.fft_sz = 0,
> +			.fft_pad_sz = 0,
> +		},
>  		.interface_modes = BIT(NL80211_IFTYPE_STATION) |
>  					BIT(NL80211_IFTYPE_AP),
>  		.supports_monitor = false,
> @@ -223,8 +232,10 @@ static const struct ath11k_hw_params ath11k_hw_params[] = {
>  		.vdev_start_delay = true,
>  		.htt_peer_map_v2 = false,
>  		.tcl_0_only = true,
> -		.spectral_fft_sz = 0,
> -
> +		.spectral = {
> +			.fft_sz = 0,
> +			.fft_pad_sz = 0,
> +		},
>  		.interface_modes = BIT(NL80211_IFTYPE_STATION) |
>  					BIT(NL80211_IFTYPE_AP),
>  		.supports_monitor = false,

QCN9074 hw1.0 didn't have an entry. I suspect what happened was that
support for wcn6855 was added between writing the patch and me
committing wcn6855 patches, which confused git.

I changed it so that both qcn9074 and wcn6855 have this:

		.spectral = {
			.fft_sz = 0,
			.fft_pad_sz = 0,
		},

-- 
https://patchwork.kernel.org/project/linux-wireless/list/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches

  reply	other threads:[~2021-09-24 14:35 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-21 18:08 [PATCH 0/4] ath11k: Add spectral scan support for QCN9074 Jouni Malinen
2021-07-21 18:08 ` [PATCH 1/4] ath11k: Refactor spectral FFT bin size Jouni Malinen
2021-09-24 14:35   ` Kalle Valo [this message]
2021-09-28  8:53   ` Kalle Valo
2021-07-21 18:08 ` [PATCH 2/4] ath11k: Introduce spectral hw configurable param Jouni Malinen
2021-07-21 18:08 ` [PATCH 3/4] ath11k: Fix the spectral minimum FFT bin count Jouni Malinen
2021-07-21 18:08 ` [PATCH 4/4] ath11k: Add spectral scan support for QCN9074 Jouni Malinen

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=87ee9erqhw.fsf@codeaurora.org \
    --to=kvalo@codeaurora.org \
    --cc=ath11k@lists.infradead.org \
    --cc=jouni@codeaurora.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=periyasa@codeaurora.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).