2019-11-06 21:34:14

by Brian Norris

[permalink] [raw]
Subject: [PATCH] rtw88: signal completion even on firmware-request failure

Otherwise, the waiters (e.g., "modprobe rtwpci") will block forever.

Fixes: f530c1961af2 ("rtw88: fix potential NULL pointer access for firmware")
Cc: Dan Carpenter <[email protected]>
Cc: Yan-Hsuan Chuang <[email protected]>
Signed-off-by: Brian Norris <[email protected]>
---
drivers/net/wireless/realtek/rtw88/main.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/drivers/net/wireless/realtek/rtw88/main.c b/drivers/net/wireless/realtek/rtw88/main.c
index de82d08ea29e..ae61415e1665 100644
--- a/drivers/net/wireless/realtek/rtw88/main.c
+++ b/drivers/net/wireless/realtek/rtw88/main.c
@@ -1026,6 +1026,7 @@ static void rtw_load_firmware_cb(const struct firmware *firmware, void *context)

if (!firmware || !firmware->data) {
rtw_err(rtwdev, "failed to request firmware\n");
+ complete_all(&fw->completion);
return;
}

--
2.24.0.rc1.363.gb1bccd3e3d-goog


2019-11-07 03:32:55

by Tony Chuang

[permalink] [raw]
Subject: RE: [PATCH] rtw88: signal completion even on firmware-request failure

> Subject: [PATCH] rtw88: signal completion even on firmware-request failure
>
> Otherwise, the waiters (e.g., "modprobe rtwpci") will block forever.
>
> Fixes: f530c1961af2 ("rtw88: fix potential NULL pointer access for firmware")
> Cc: Dan Carpenter <[email protected]>
> Cc: Yan-Hsuan Chuang <[email protected]>
> Signed-off-by: Brian Norris <[email protected]>
Acked-by: Yan-Hsuan Chuang <[email protected]>

2019-11-08 08:28:19

by Kalle Valo

[permalink] [raw]
Subject: Re: [PATCH] rtw88: signal completion even on firmware-request failure

Brian Norris <[email protected]> wrote:

> Otherwise, the waiters (e.g., "modprobe rtwpci") will block forever.
>
> Fixes: f530c1961af2 ("rtw88: fix potential NULL pointer access for firmware")
> Cc: Dan Carpenter <[email protected]>
> Cc: Yan-Hsuan Chuang <[email protected]>
> Signed-off-by: Brian Norris <[email protected]>
> Acked-by: Yan-Hsuan Chuang <[email protected]>

Patch applied to wireless-drivers-next.git, thanks.

21c60a28af58 rtw88: signal completion even on firmware-request failure

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

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