diff mbox series

[1/2] brcmfmac: fix system warning message during wowl suspend

Message ID 1546501565-40752-2-git-send-email-chi-hsien.lin@cypress.com (mailing list archive)
State Changes Requested
Delegated to: Kalle Valo
Headers show
Series brcmfmac: wake on wireless LAN changes | expand

Commit Message

Chi-Hsien Lin Jan. 3, 2019, 7:46 a.m. UTC
From: Lo-Hsiang Lo <double.lo@cypress.com>

There is a system warning message, warn_slowpath-fmt, during suspend
while using supplicant join AP and enable wowl feature by IW command.
It's cuased by brcmf_pno_remove_request path can't find the reqid.
This fix will not go to remove pno request function if there is no
pno scan.

Signed-off-by: Lo-Hsiang Lo <double.lo@cypress.com>
Signed-off-by: Chi-Hsien Lin <chi-hsien.lin@cypress.com>
---
 drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c | 5 +++++
 1 file changed, 5 insertions(+)

Comments

James Hughes Jan. 3, 2019, 9:56 a.m. UTC | #1
On Thu, 3 Jan 2019 at 07:46, Chi-Hsien Lin <Chi-Hsien.Lin@cypress.com> wrote:
>
> From: Lo-Hsiang Lo <double.lo@cypress.com>
>
> There is a system warning message, warn_slowpath-fmt, during suspend
> while using supplicant join AP and enable wowl feature by IW command.
> It's cuased by brcmf_pno_remove_request path can't find the reqid.
> This fix will not go to remove pno request function if there is no
> pno scan.

Typo in the commit message `cuased`

>
> Signed-off-by: Lo-Hsiang Lo <double.lo@cypress.com>
> Signed-off-by: Chi-Hsien Lin <chi-hsien.lin@cypress.com>
> ---
>  drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
> index ffa243e2e2d0..55974a43796a 100644
> --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
> +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
> @@ -496,6 +496,11 @@ int brcmf_pno_stop_sched_scan(struct brcmf_if *ifp, u64 reqid)
>         brcmf_dbg(TRACE, "reqid=%llu\n", reqid);
>
>         pi = ifp_to_pno(ifp);
> +
> +       /* No PNO reqeuset */

Typo. `reqeuset`

> +       if (!pi->n_reqs)
> +               return 0;
> +
>         err = brcmf_pno_remove_request(pi, reqid);
>         if (err)
>                 return err;
> --
> 2.1.0
>
Arend van Spriel Jan. 4, 2019, 11:37 a.m. UTC | #2
On 1/3/2019 8:46 AM, Chi-Hsien Lin wrote:
> From: Lo-Hsiang Lo <double.lo@cypress.com>
> 
> There is a system warning message, warn_slowpath-fmt, during suspend
> while using supplicant join AP and enable wowl feature by IW command.
> It's cuased by brcmf_pno_remove_request path can't find the reqid.
> This fix will not go to remove pno request function if there is no
> pno scan.

Acked-by: Arend van Spriel <arend.vanspriel@broadcom.com>
> Signed-off-by: Lo-Hsiang Lo <double.lo@cypress.com>
> Signed-off-by: Chi-Hsien Lin <chi-hsien.lin@cypress.com>
> ---
>   drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c | 5 +++++
>   1 file changed, 5 insertions(+)
Chi-Hsien Lin Jan. 7, 2019, 9:16 a.m. UTC | #3
On 01/03/2019 5:56, James Hughes wrote:
> On Thu, 3 Jan 2019 at 07:46, Chi-Hsien Lin <Chi-Hsien.Lin@cypress.com> wrote:
>>
>> From: Lo-Hsiang Lo <double.lo@cypress.com>
>>
>> There is a system warning message, warn_slowpath-fmt, during suspend
>> while using supplicant join AP and enable wowl feature by IW command.
>> It's cuased by brcmf_pno_remove_request path can't find the reqid.
>> This fix will not go to remove pno request function if there is no
>> pno scan.
> 
> Typo in the commit message `cuased`

James,

Thanks for catching this. I've submitted V2 to fix both typos.

> 
>>
>> Signed-off-by: Lo-Hsiang Lo <double.lo@cypress.com>
>> Signed-off-by: Chi-Hsien Lin <chi-hsien.lin@cypress.com>
>> ---
>>   drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c | 5 +++++
>>   1 file changed, 5 insertions(+)
>>
>> diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
>> index ffa243e2e2d0..55974a43796a 100644
>> --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
>> +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
>> @@ -496,6 +496,11 @@ int brcmf_pno_stop_sched_scan(struct brcmf_if *ifp, u64 reqid)
>>          brcmf_dbg(TRACE, "reqid=%llu\n", reqid);
>>
>>          pi = ifp_to_pno(ifp);
>> +
>> +       /* No PNO reqeuset */
> 
> Typo. `reqeuset`
> 
>> +       if (!pi->n_reqs)
>> +               return 0;
>> +
>>          err = brcmf_pno_remove_request(pi, reqid);
>>          if (err)
>>                  return err;
>> --
>> 2.1.0
>>
diff mbox series

Patch

diff --git a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
index ffa243e2e2d0..55974a43796a 100644
--- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
+++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/pno.c
@@ -496,6 +496,11 @@  int brcmf_pno_stop_sched_scan(struct brcmf_if *ifp, u64 reqid)
 	brcmf_dbg(TRACE, "reqid=%llu\n", reqid);
 
 	pi = ifp_to_pno(ifp);
+
+	/* No PNO reqeuset */
+	if (!pi->n_reqs)
+		return 0;
+
 	err = brcmf_pno_remove_request(pi, reqid);
 	if (err)
 		return err;