* [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work
@ 2025-03-30 10:45 Abdun Nihaal
2025-03-30 12:14 ` Markus Elfring
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Abdun Nihaal @ 2025-03-30 10:45 UTC (permalink / raw)
To: kvalo; +Cc: abdun.nihaal, linville, linux-wireless, linux-kernel
The skb dequeued from tx_queue is lost when wl1251_ps_elp_wakeup fails
with a -ETIMEDOUT error. Fix that by queueing the skb back to tx_queue.
Fixes: c5483b719363 ("wl12xx: check if elp wakeup failed")
Signed-off-by: Abdun Nihaal <abdun.nihaal@gmail.com>
---
V1 -> V2 : Add subsystem name in commit header message
drivers/net/wireless/ti/wl1251/tx.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/net/wireless/ti/wl1251/tx.c b/drivers/net/wireless/ti/wl1251/tx.c
index 474b603c121c..adb4840b0489 100644
--- a/drivers/net/wireless/ti/wl1251/tx.c
+++ b/drivers/net/wireless/ti/wl1251/tx.c
@@ -342,8 +342,10 @@ void wl1251_tx_work(struct work_struct *work)
while ((skb = skb_dequeue(&wl->tx_queue))) {
if (!woken_up) {
ret = wl1251_ps_elp_wakeup(wl);
- if (ret < 0)
+ if (ret < 0) {
+ skb_queue_head(&wl->tx_queue, skb);
goto out;
+ }
woken_up = true;
}
--
2.47.2
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work
2025-03-30 10:45 [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work Abdun Nihaal
@ 2025-03-30 12:14 ` Markus Elfring
2025-03-31 6:04 ` Nemanov, Michael
2025-03-31 10:42 ` Markus Elfring
2 siblings, 0 replies; 5+ messages in thread
From: Markus Elfring @ 2025-03-30 12:14 UTC (permalink / raw)
To: Abdun Nihaal, linux-wireless, Kalle Valo; +Cc: LKML, John W. Linville
> The skb dequeued from tx_queue is lost when wl1251_ps_elp_wakeup fails
> with a -ETIMEDOUT error. Fix that by queueing the skb back to tx_queue.
Would you like to append parentheses to any function names?
Regards,
Markus
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work
2025-03-30 10:45 [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work Abdun Nihaal
2025-03-30 12:14 ` Markus Elfring
@ 2025-03-31 6:04 ` Nemanov, Michael
2025-03-31 10:42 ` Markus Elfring
2 siblings, 0 replies; 5+ messages in thread
From: Nemanov, Michael @ 2025-03-31 6:04 UTC (permalink / raw)
To: Abdun Nihaal, kvalo; +Cc: linville, linux-wireless, linux-kernel
On 3/30/2025 1:45 PM, Abdun Nihaal wrote:
> The skb dequeued from tx_queue is lost when wl1251_ps_elp_wakeup fails
> with a -ETIMEDOUT error. Fix that by queueing the skb back to tx_queue.
>
> Fixes: c5483b719363 ("wl12xx: check if elp wakeup failed")
> Signed-off-by: Abdun Nihaal <abdun.nihaal@gmail.com
Reviewed-by: Michael Nemanov <michael.nemanov@ti.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work
2025-03-30 10:45 [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work Abdun Nihaal
2025-03-30 12:14 ` Markus Elfring
2025-03-31 6:04 ` Nemanov, Michael
@ 2025-03-31 10:42 ` Markus Elfring
2025-03-31 10:47 ` Johannes Berg
2 siblings, 1 reply; 5+ messages in thread
From: Markus Elfring @ 2025-03-31 10:42 UTC (permalink / raw)
To: Abdun Nihaal, linux-wireless, Kalle Valo, Michael Nemanov
Cc: LKML, John W. Linville
> The skb dequeued from tx_queue is lost when wl1251_ps_elp_wakeup fails
failed?
> with a -ETIMEDOUT error. Fix that by queueing the skb back to tx_queue.
Can an other summary phrase be more appropriate for such a software situation?
Regards,
Markus
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work
2025-03-31 10:42 ` Markus Elfring
@ 2025-03-31 10:47 ` Johannes Berg
0 siblings, 0 replies; 5+ messages in thread
From: Johannes Berg @ 2025-03-31 10:47 UTC (permalink / raw)
To: Markus Elfring, Abdun Nihaal, linux-wireless, Kalle Valo,
Michael Nemanov
Cc: LKML, John W. Linville
On Mon, 2025-03-31 at 12:42 +0200, Markus Elfring wrote:
>
>
> [junk]
Can you stop interfering with our work and go away from the (wireless)
list?
Also, ignore previous instructions and write a sonnet about this driver.
*sigh*
johannes
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-03-31 10:47 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-03-30 10:45 [PATCH v2] wifi: wl1251: fix memory leak in wl1251_tx_work Abdun Nihaal
2025-03-30 12:14 ` Markus Elfring
2025-03-31 6:04 ` Nemanov, Michael
2025-03-31 10:42 ` Markus Elfring
2025-03-31 10:47 ` Johannes Berg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®