* [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend
@ 2020-05-20 12:57 Dinghao Liu
2020-05-20 18:48 ` Tony Lindgren
2020-05-29 17:34 ` Kalle Valo
0 siblings, 2 replies; 5+ messages in thread
From: Dinghao Liu @ 2020-05-20 12:57 UTC (permalink / raw)
To: dinghao.liu, kjlu
Cc: Kalle Valo, David S. Miller, Jakub Kicinski, Thomas Gleixner,
Johannes Berg, Greg Kroah-Hartman, Maital Hahn, Fuqian Huang,
Emmanuel Grumbach, Jason A. Donenfeld, Tony Lindgren,
linux-wireless, netdev, linux-kernel
When wlcore_hw_interrupt_notify() returns an error code,
a pairing runtime PM usage counter decrement is needed to
keep the counter balanced.
Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
---
drivers/net/wireless/ti/wlcore/main.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/net/wireless/ti/wlcore/main.c b/drivers/net/wireless/ti/wlcore/main.c
index f140f7d7f553..8faee8cec1bc 100644
--- a/drivers/net/wireless/ti/wlcore/main.c
+++ b/drivers/net/wireless/ti/wlcore/main.c
@@ -1746,9 +1746,7 @@ static int __maybe_unused wl1271_op_suspend(struct ieee80211_hw *hw,
ret = wl1271_configure_suspend(wl, wlvif, wow);
if (ret < 0) {
- mutex_unlock(&wl->mutex);
- wl1271_warning("couldn't prepare device to suspend");
- return ret;
+ goto out_sleep;
}
}
--
2.17.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend
2020-05-20 12:57 [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend Dinghao Liu
@ 2020-05-20 18:48 ` Tony Lindgren
2020-05-21 4:51 ` dinghao.liu
2020-05-29 17:34 ` Kalle Valo
1 sibling, 1 reply; 5+ messages in thread
From: Tony Lindgren @ 2020-05-20 18:48 UTC (permalink / raw)
To: Dinghao Liu
Cc: kjlu, Kalle Valo, David S. Miller, Jakub Kicinski,
Thomas Gleixner, Johannes Berg, Greg Kroah-Hartman, Maital Hahn,
Fuqian Huang, Emmanuel Grumbach, Jason A. Donenfeld,
linux-wireless, netdev, linux-kernel
* Dinghao Liu <dinghao.liu@zju.edu.cn> [200520 12:58]:
> When wlcore_hw_interrupt_notify() returns an error code,
> a pairing runtime PM usage counter decrement is needed to
> keep the counter balanced.
We should probably keep the warning though, nothing will
get shown for wl1271_configure_suspend_ap() errors.
Otherwise looks good to me.
Regards,
Tony
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Re: [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend
2020-05-20 18:48 ` Tony Lindgren
@ 2020-05-21 4:51 ` dinghao.liu
2020-05-21 15:59 ` Tony Lindgren
0 siblings, 1 reply; 5+ messages in thread
From: dinghao.liu @ 2020-05-21 4:51 UTC (permalink / raw)
To: Tony Lindgren
Cc: kjlu, Kalle Valo, David S. Miller, Jakub Kicinski,
Thomas Gleixner, Johannes Berg, Greg Kroah-Hartman, Maital Hahn,
Fuqian Huang, Emmanuel Grumbach, Jason A. Donenfeld,
linux-wireless, netdev, linux-kernel
There is a check against ret after out_sleep tag. If wl1271_configure_suspend_ap()
returns an error code, ret will be caught by this check and a warning will be issued.
"Tony Lindgren" <tony@atomide.com>写道:
> * Dinghao Liu <dinghao.liu@zju.edu.cn> [200520 12:58]:
> > When wlcore_hw_interrupt_notify() returns an error code,
> > a pairing runtime PM usage counter decrement is needed to
> > keep the counter balanced.
>
> We should probably keep the warning though, nothing will
> get shown for wl1271_configure_suspend_ap() errors.
>
> Otherwise looks good to me.
>
> Regards,
>
> Tony
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Re: [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend
2020-05-21 4:51 ` dinghao.liu
@ 2020-05-21 15:59 ` Tony Lindgren
0 siblings, 0 replies; 5+ messages in thread
From: Tony Lindgren @ 2020-05-21 15:59 UTC (permalink / raw)
To: dinghao.liu
Cc: kjlu, Kalle Valo, David S. Miller, Jakub Kicinski,
Thomas Gleixner, Johannes Berg, Greg Kroah-Hartman, Maital Hahn,
Fuqian Huang, Emmanuel Grumbach, Jason A. Donenfeld,
linux-wireless, netdev, linux-kernel
* dinghao.liu@zju.edu.cn <dinghao.liu@zju.edu.cn> [200521 04:55]:
> There is a check against ret after out_sleep tag. If wl1271_configure_suspend_ap()
> returns an error code, ret will be caught by this check and a warning will be issued.
OK thanks for checking. In that case this one too:
Acked-by: Tony Lindgren <tony@atomide.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend
2020-05-20 12:57 [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend Dinghao Liu
2020-05-20 18:48 ` Tony Lindgren
@ 2020-05-29 17:34 ` Kalle Valo
1 sibling, 0 replies; 5+ messages in thread
From: Kalle Valo @ 2020-05-29 17:34 UTC (permalink / raw)
To: Dinghao Liu
Cc: dinghao.liu, kjlu, David S. Miller, Jakub Kicinski,
Thomas Gleixner, Johannes Berg, Greg Kroah-Hartman, Maital Hahn,
Fuqian Huang, Emmanuel Grumbach, Jason A. Donenfeld,
Tony Lindgren, linux-wireless, netdev, linux-kernel
Dinghao Liu <dinghao.liu@zju.edu.cn> wrote:
> When wlcore_hw_interrupt_notify() returns an error code,
> a pairing runtime PM usage counter decrement is needed to
> keep the counter balanced.
>
> Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn>
> Acked-by: Tony Lindgren <tony@atomide.com>
Patch applied to wireless-drivers-next.git, thanks.
3e69ed2b52fd wlcore: fix runtime pm imbalance in wl1271_op_suspend
--
https://patchwork.kernel.org/patch/11560333/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2020-05-29 17:35 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-20 12:57 [PATCH] wlcore: fix runtime pm imbalance in wl1271_op_suspend Dinghao Liu
2020-05-20 18:48 ` Tony Lindgren
2020-05-21 4:51 ` dinghao.liu
2020-05-21 15:59 ` Tony Lindgren
2020-05-29 17:34 ` Kalle Valo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).