All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pkshih <pkshih@realtek.com>
To: "kvalo@codeaurora.org" <kvalo@codeaurora.org>,
	"ath10k@lists.infradead.org" <ath10k@lists.infradead.org>
Cc: "linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH 2/2] ath10k: allow dynamic SAR power limits to be configured
Date: Thu, 19 Dec 2019 09:45:14 +0000	[thread overview]
Message-ID: <1576748714.7758.18.camel@realtek.com> (raw)
In-Reply-To: <1576684108-30177-3-git-send-email-kvalo@codeaurora.org>

On Wed, 2019-12-18 at 17:48 +0200, Kalle Valo wrote:
> From: Wen Gong <wgong@codeaurora.org>
> 
> Add support for a vendor command for STATION, the command
> QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS which is already defined in
> git://w1.fi/hostap.git (src/command/qca-vendor.h). This allows user
> space to configure power limits for 2.4 GHz and 5 GHz bands.
> 
> ath10k set pdev parameter WMI_PDEV_PARAM_TXPOWER_LIMIT2G and
> WMI_PDEV_PARAM_TXPOWER_LIMIT5G to firmware, the 2 value will
> be used as one input source to affect the tx power.
> 
> When QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS set to ath10k, it will
> be saved the 2.4G and 5G limit value, If STATION is connected meanwhile,
> then the 2.4G and 5G WMI command will be set to firmware, otherwise
> it will not set to firmware at this moment. When STATION connect
> next time, it will set to firmware.
> 
> Tested with QCA6174 SDIO with firmware WLAN.RMH.4.4.1-00029.
> 
> Signed-off-by: Wen Gong <wgong@codeaurora.org>
> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
> ---
>  drivers/net/wireless/ath/ath10k/Makefile |   1 +
>  drivers/net/wireless/ath/ath10k/core.c   |   2 +
>  drivers/net/wireless/ath/ath10k/core.h   |   2 +
>  drivers/net/wireless/ath/ath10k/hw.h     |   3 +
>  drivers/net/wireless/ath/ath10k/mac.c    |  64 +++++++++++++++++
>  drivers/net/wireless/ath/ath10k/mac.h    |   2 +-
>  drivers/net/wireless/ath/ath10k/vendor.c | 114
> +++++++++++++++++++++++++++++++
>  drivers/net/wireless/ath/ath10k/vendor.h |  13 ++++
>  drivers/net/wireless/ath/ath10k/wmi.h    |   6 ++
>  9 files changed, 206 insertions(+), 1 deletion(-)
>  create mode 100644 drivers/net/wireless/ath/ath10k/vendor.c
>  create mode 100644 drivers/net/wireless/ath/ath10k/vendor.h
> 

[...]

> diff --git a/drivers/net/wireless/ath/ath10k/wmi.h
> b/drivers/net/wireless/ath/ath10k/wmi.h
> index 972d53d77654..f0cadaa12399 100644
> --- a/drivers/net/wireless/ath/ath10k/wmi.h
> +++ b/drivers/net/wireless/ath/ath10k/wmi.h
> @@ -3695,6 +3695,12 @@ struct wmi_csa_event {
>  #define VDEV_DEFAULT_STATS_UPDATE_PERIOD    500
>  #define PEER_DEFAULT_STATS_UPDATE_PERIOD    500
>  
> +/* the mask of 4 sub band of 5G for SAR parameters */
> +#define ATH10K_WMI_SAR_5G_0_MASK GENMASK(7, 0)
> +#define ATH10K_WMI_SAR_5G_1_MASK GENMASK(15, 8)
> +#define ATH10K_WMI_SAR_5G_2_MASK GENMASK(23, 16)
> +#define ATH10K_WMI_SAR_5G_3_MASK GENMASK(31, 24)
> +

These masks aren't used.
Do you use 'u32' as four 'u8' SAR power limit for four bands?

>  struct wmi_pdev_param_map {
>  	u32 tx_chain_mask;
>  	u32 rx_chain_mask;

WARNING: multiple messages have this Message-ID
From: Pkshih <pkshih@realtek.com>
To: "kvalo@codeaurora.org" <kvalo@codeaurora.org>,
	"ath10k@lists.infradead.org" <ath10k@lists.infradead.org>
Cc: "linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH 2/2] ath10k: allow dynamic SAR power limits to be configured
Date: Thu, 19 Dec 2019 09:45:14 +0000	[thread overview]
Message-ID: <1576748714.7758.18.camel@realtek.com> (raw)
In-Reply-To: <1576684108-30177-3-git-send-email-kvalo@codeaurora.org>

On Wed, 2019-12-18 at 17:48 +0200, Kalle Valo wrote:
> From: Wen Gong <wgong@codeaurora.org>
> 
> Add support for a vendor command for STATION, the command
> QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS which is already defined in
> git://w1.fi/hostap.git (src/command/qca-vendor.h). This allows user
> space to configure power limits for 2.4 GHz and 5 GHz bands.
> 
> ath10k set pdev parameter WMI_PDEV_PARAM_TXPOWER_LIMIT2G and
> WMI_PDEV_PARAM_TXPOWER_LIMIT5G to firmware, the 2 value will
> be used as one input source to affect the tx power.
> 
> When QCA_NL80211_VENDOR_SUBCMD_SET_SAR_LIMITS set to ath10k, it will
> be saved the 2.4G and 5G limit value, If STATION is connected meanwhile,
> then the 2.4G and 5G WMI command will be set to firmware, otherwise
> it will not set to firmware at this moment. When STATION connect
> next time, it will set to firmware.
> 
> Tested with QCA6174 SDIO with firmware WLAN.RMH.4.4.1-00029.
> 
> Signed-off-by: Wen Gong <wgong@codeaurora.org>
> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
> ---
>  drivers/net/wireless/ath/ath10k/Makefile |   1 +
>  drivers/net/wireless/ath/ath10k/core.c   |   2 +
>  drivers/net/wireless/ath/ath10k/core.h   |   2 +
>  drivers/net/wireless/ath/ath10k/hw.h     |   3 +
>  drivers/net/wireless/ath/ath10k/mac.c    |  64 +++++++++++++++++
>  drivers/net/wireless/ath/ath10k/mac.h    |   2 +-
>  drivers/net/wireless/ath/ath10k/vendor.c | 114
> +++++++++++++++++++++++++++++++
>  drivers/net/wireless/ath/ath10k/vendor.h |  13 ++++
>  drivers/net/wireless/ath/ath10k/wmi.h    |   6 ++
>  9 files changed, 206 insertions(+), 1 deletion(-)
>  create mode 100644 drivers/net/wireless/ath/ath10k/vendor.c
>  create mode 100644 drivers/net/wireless/ath/ath10k/vendor.h
> 

[...]

> diff --git a/drivers/net/wireless/ath/ath10k/wmi.h
> b/drivers/net/wireless/ath/ath10k/wmi.h
> index 972d53d77654..f0cadaa12399 100644
> --- a/drivers/net/wireless/ath/ath10k/wmi.h
> +++ b/drivers/net/wireless/ath/ath10k/wmi.h
> @@ -3695,6 +3695,12 @@ struct wmi_csa_event {
>  #define VDEV_DEFAULT_STATS_UPDATE_PERIOD    500
>  #define PEER_DEFAULT_STATS_UPDATE_PERIOD    500
>  
> +/* the mask of 4 sub band of 5G for SAR parameters */
> +#define ATH10K_WMI_SAR_5G_0_MASK GENMASK(7, 0)
> +#define ATH10K_WMI_SAR_5G_1_MASK GENMASK(15, 8)
> +#define ATH10K_WMI_SAR_5G_2_MASK GENMASK(23, 16)
> +#define ATH10K_WMI_SAR_5G_3_MASK GENMASK(31, 24)
> +

These masks aren't used.
Do you use 'u32' as four 'u8' SAR power limit for four bands?

>  struct wmi_pdev_param_map {
>  	u32 tx_chain_mask;
>  	u32 rx_chain_mask;
_______________________________________________
ath10k mailing list
ath10k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath10k

  reply	other threads:[~2019-12-19  9:45 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-18 15:48 [PATCH 0/2] ath10k: SAR power limit vendor command Kalle Valo
2019-12-18 15:48 ` Kalle Valo
2019-12-18 15:48 ` [PATCH 1/2] nl80211: vendor-cmd: qca: add dynamic SAR power limits Kalle Valo
2019-12-18 15:48   ` Kalle Valo
2019-12-19  9:44   ` Pkshih
2019-12-19  9:44     ` Pkshih
2019-12-19 15:48     ` Jouni Malinen
2019-12-19 15:48       ` Jouni Malinen
2019-12-19 18:32       ` Brian Norris
2019-12-19 18:32         ` Brian Norris
2019-12-19 18:55         ` Jouni Malinen
2019-12-19 18:55           ` Jouni Malinen
2019-12-19 23:40           ` Brian Norris
2019-12-19 23:40             ` Brian Norris
2020-03-17 16:54             ` Kalle Valo
2020-03-17 16:54               ` Kalle Valo
2020-03-20 12:55               ` Johannes Berg
2020-03-20 12:55                 ` Johannes Berg
2020-06-02  1:32                 ` Brian Norris
2020-06-02  1:32                   ` Brian Norris
2020-07-16  9:35                   ` Kalle Valo
2020-07-16  9:35                     ` Kalle Valo
2020-07-16 18:56                     ` Brian Norris
2020-07-16 18:56                       ` Brian Norris
2020-07-24  9:26                       ` Kalle Valo
2020-07-24  9:26                         ` Kalle Valo
2020-07-30 13:24                         ` Johannes Berg
2020-07-30 13:24                           ` Johannes Berg
2020-08-01  1:31                           ` Brian Norris
2020-08-01  1:31                             ` Brian Norris
2020-09-08  5:55                           ` Kalle Valo
2020-09-08  5:55                           ` Kalle Valo
2020-07-30 13:17                   ` Johannes Berg
2020-07-30 13:17                     ` Johannes Berg
2019-12-18 15:48 ` [PATCH 2/2] ath10k: allow dynamic SAR power limits to be configured Kalle Valo
2019-12-18 15:48   ` Kalle Valo
2019-12-19  9:45   ` Pkshih [this message]
2019-12-19  9:45     ` Pkshih
2020-04-16  7:38   ` Kalle Valo
2020-04-16  7:38   ` Kalle Valo

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=1576748714.7758.18.camel@realtek.com \
    --to=pkshih@realtek.com \
    --cc=ath10k@lists.infradead.org \
    --cc=kvalo@codeaurora.org \
    --cc=linux-wireless@vger.kernel.org \
    --subject='Re: [PATCH 2/2] ath10k: allow dynamic SAR power limits to be configured' \
    /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

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.