From: "Valo, Kalle" <kvalo@qca.qualcomm.com>
To: Eric Bentley <eric.bentley@lairdtech.com>
Cc: "ath6kl@lists.infradead.org" <ath6kl@lists.infradead.org>,
"linux-wireless@vger.kernel.org" <linux-wireless@vger.kernel.org>
Subject: Re: [PATCH] ath6kl: Allow the radio to report 0 dbm txpower without timing out
Date: Tue, 30 Aug 2016 06:28:39 +0000 [thread overview]
Message-ID: <871t16ahyh.fsf@kamboji.qca.qualcomm.com> (raw)
In-Reply-To: <1472537779-3723-1-git-send-email-eric.bentley@lairdtech.com> (Eric Bentley's message of "Tue, 30 Aug 2016 02:16:19 -0400")
Eric Bentley <eric.bentley@lairdtech.com> writes:
> The ath6kl driver attempts to get the txpower value from the radio by fir=
st
> clearing the existing stored value and then watching the value to become
> non-zero.
>
> APs allow setting client power to values from -127..127, but this radio
> is not capable of setting values less then 0 and so will report txpower
> as 0dbm for both negative and 0 client power values.
>
> When the radio has txpower set to 0dbm txpower (equivalent to 1mw) the
> ath6kl_cfg80211_get_txpower() function will remain in the
> wait_event_interruptible_timeout() loop waiting for the value to be
> non-zero, and will eventually timeout. This results in a 5 second delay i=
n
> response. However, the correct value of zero is eventually returned.
>
> The 6004 defaults to 63dbm which is then limited by regulatory and
> hardware limits with max of 18dbm (6003 max is 16dbm), therefore we can
> use values larger then these to be able to determine when the value has
> been updated.
>
> To correct the issue, set the value to a nonsensical value (255) and wait
> for it to change to the valid value.
>
> --
> Tested on both 6003 and 6004 based radios. Return value of zero is
> correctly returned in an expected amount of time (similar to when
> returning non-zero values) when AP client power is set to both 0 and
> negative values.
>
> Signed-off-by: Eric Bentley <eric.bentley@lairdtech.com>
This is perfect now, thanks. I'll just remove the "--" line from the
commit log, that looks a bit weird.
--=20
Kalle Valo=
next prev parent reply other threads:[~2016-08-30 6:28 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-30 6:16 [PATCH] ath6kl: Allow the radio to report 0 dbm txpower without timing out Eric Bentley
2016-08-30 6:28 ` Valo, Kalle [this message]
2016-09-09 12:14 ` 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=871t16ahyh.fsf@kamboji.qca.qualcomm.com \
--to=kvalo@qca.qualcomm.com \
--cc=ath6kl@lists.infradead.org \
--cc=eric.bentley@lairdtech.com \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox