diff mbox series

[1/3] ath6kl: Only use match sets when firmware supports it

Message ID 20181108163659.19535-1-kyle.roeschley@ni.com (mailing list archive)
State Accepted
Commit fb376a495fbdb886f38cfaf5a3805401b9e46f13
Delegated to: Kalle Valo
Headers show
Series [1/3] ath6kl: Only use match sets when firmware supports it | expand

Commit Message

Kyle Roeschley Nov. 8, 2018, 4:36 p.m. UTC
Commit dd45b7598f1c ("ath6kl: Include match ssid list in scheduled scan")
merged the probed and matched SSID lists before sending them to the
firmware. In the process, it assumed match set support is always available
in ath6kl_set_probed_ssids, which breaks scans for hidden SSIDs. Now, check
that the firmware supports matching SSIDs in scheduled scans before setting
MATCH_SSID_FLAG.

Fixes: dd45b7598f1c ("ath6kl: Include match ssid list in scheduled scan")
Signed-off-by: Kyle Roeschley <kyle.roeschley@ni.com>
---
 drivers/net/wireless/ath/ath6kl/cfg80211.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Kyle Roeschley Nov. 30, 2018, 8:16 p.m. UTC | #1
Hi Kalle,

Have you had a chance to check out these patches yet?
Kalle Valo Dec. 3, 2018, 8:41 a.m. UTC | #2
Kyle Roeschley <kyle.roeschley@ni.com> writes:

> Have you had a chance to check out these patches yet?

Not yet, I have been busy with something else. BTW, you can check the
status from patchwork:

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches#checking_state_of_patches_from_patchwork
Kyle Roeschley Dec. 3, 2018, 3:27 p.m. UTC | #3
On Mon, Dec 03, 2018 at 10:41:02AM +0200, Kalle Valo wrote:
> Kyle Roeschley <kyle.roeschley@ni.com> writes:
> 
> > Have you had a chance to check out these patches yet?
> 
> Not yet, I have been busy with something else. BTW, you can check the
> status from patchwork:

Whoops, I should have read the linux-wireless docs more carefully. Thanks for
the clarification, and sorry for the noise.
Kalle Valo Dec. 20, 2018, 7:31 a.m. UTC | #4
Kyle Roeschley <kyle.roeschley@ni.com> wrote:

> Commit dd45b7598f1c ("ath6kl: Include match ssid list in scheduled scan")
> merged the probed and matched SSID lists before sending them to the
> firmware. In the process, it assumed match set support is always available
> in ath6kl_set_probed_ssids, which breaks scans for hidden SSIDs. Now, check
> that the firmware supports matching SSIDs in scheduled scans before setting
> MATCH_SSID_FLAG.
> 
> Fixes: dd45b7598f1c ("ath6kl: Include match ssid list in scheduled scan")
> Signed-off-by: Kyle Roeschley <kyle.roeschley@ni.com>
> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>

3 patches applied to ath-next branch of ath.git, thanks.

fb376a495fbd ath6kl: Only use match sets when firmware supports it
5803c12816c4 ath6kl: Fix off by one error in scan completion
192a986d964c ath6kl: Use debug instead of error message when disabled
diff mbox series

Patch

diff --git a/drivers/net/wireless/ath/ath6kl/cfg80211.c b/drivers/net/wireless/ath/ath6kl/cfg80211.c
index e121187f371f..6c98d7903ffb 100644
--- a/drivers/net/wireless/ath/ath6kl/cfg80211.c
+++ b/drivers/net/wireless/ath/ath6kl/cfg80211.c
@@ -939,7 +939,7 @@  static int ath6kl_set_probed_ssids(struct ath6kl *ar,
 		else
 			ssid_list[i].flag = ANY_SSID_FLAG;
 
-		if (n_match_ssid == 0)
+		if (ar->wiphy->max_match_sets != 0 && n_match_ssid == 0)
 			ssid_list[i].flag |= MATCH_SSID_FLAG;
 	}