2018-11-08 16:37:34

by Kyle Roeschley

[permalink] [raw]
Subject: [PATCH 1/3] ath6kl: Only use match sets when firmware supports it

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 <[email protected]>
---
drivers/net/wireless/ath/ath6kl/cfg80211.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

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;
}

--
2.19.1



2018-11-08 16:37:21

by Kyle Roeschley

[permalink] [raw]
Subject: [PATCH 3/3] ath6kl: Use debug instead of error message when disabled

This is not an unexpected condition, so we don't need to be shouting to the
world about it.

Signed-off-by: Kyle Roeschley <[email protected]>
---
drivers/net/wireless/ath/ath6kl/cfg80211.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/wireless/ath/ath6kl/cfg80211.c b/drivers/net/wireless/ath/ath6kl/cfg80211.c
index d7c626d9594e..59dd50866932 100644
--- a/drivers/net/wireless/ath/ath6kl/cfg80211.c
+++ b/drivers/net/wireless/ath/ath6kl/cfg80211.c
@@ -291,7 +291,7 @@ static bool ath6kl_cfg80211_ready(struct ath6kl_vif *vif)
}

if (!test_bit(WLAN_ENABLED, &vif->flags)) {
- ath6kl_err("wlan disabled\n");
+ ath6kl_dbg(ATH6KL_DBG_WLAN_CFG, "wlan disabled\n");
return false;
}

--
2.19.1


2018-11-08 16:37:28

by Kyle Roeschley

[permalink] [raw]
Subject: [PATCH 2/3] ath6kl: Fix off by one error in scan completion

When ath6kl was reworked to share code between regular and scheduled scans
in commit 3b8ffc6a22ba ("ath6kl: Configure probed SSID list consistently"),
probed SSID entry changed from 1-index to 0-indexed. However,
ath6kl_cfg80211_scan_complete_event() was missed in that change. Fix its
indexing so that we correctly clear out the probed SSID list.

Signed-off-by: Kyle Roeschley <[email protected]>
---
drivers/net/wireless/ath/ath6kl/cfg80211.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/wireless/ath/ath6kl/cfg80211.c b/drivers/net/wireless/ath/ath6kl/cfg80211.c
index 6c98d7903ffb..d7c626d9594e 100644
--- a/drivers/net/wireless/ath/ath6kl/cfg80211.c
+++ b/drivers/net/wireless/ath/ath6kl/cfg80211.c
@@ -1093,7 +1093,7 @@ void ath6kl_cfg80211_scan_complete_event(struct ath6kl_vif *vif, bool aborted)
if (vif->scan_req->n_ssids && vif->scan_req->ssids[0].ssid_len) {
for (i = 0; i < vif->scan_req->n_ssids; i++) {
ath6kl_wmi_probedssid_cmd(ar->wmi, vif->fw_vif_idx,
- i + 1, DISABLE_SSID_FLAG,
+ i, DISABLE_SSID_FLAG,
0, NULL);
}
}
--
2.19.1


2018-11-30 20:17:07

by Kyle Roeschley

[permalink] [raw]
Subject: Re: [PATCH 1/3] ath6kl: Only use match sets when firmware supports it

Hi Kalle,

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

--
Kyle Roeschley
Software Engineer
National Instruments

2018-12-03 08:41:17

by Kalle Valo

[permalink] [raw]
Subject: Re: [PATCH 1/3] ath6kl: Only use match sets when firmware supports it

Kyle Roeschley <[email protected]> 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

--
Kalle Valo

2018-12-03 15:27:23

by Kyle Roeschley

[permalink] [raw]
Subject: Re: [PATCH 1/3] ath6kl: Only use match sets when firmware supports it

On Mon, Dec 03, 2018 at 10:41:02AM +0200, Kalle Valo wrote:
> Kyle Roeschley <[email protected]> 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.

--
Kyle Roeschley

2018-12-20 07:31:30

by Kalle Valo

[permalink] [raw]
Subject: Re: [PATCH 1/3] ath6kl: Only use match sets when firmware supports it

Kyle Roeschley <[email protected]> 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 <[email protected]>
> Signed-off-by: Kalle Valo <[email protected]>

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

--
https://patchwork.kernel.org/patch/10674651/

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