Re: [PATCH net] usbnet: Fix memory leak in usbnet_disconnect()

From: patchwork-bot+netdevbpf
Date: Mon Sep 26 2022 - 14:42:34 EST


Hello:

This patch was applied to netdev/net.git (master)
by Jakub Kicinski <kuba@xxxxxxxxxx>:

On Thu, 22 Sep 2022 21:25:51 -0700 you wrote:
> From: Peilin Ye <peilin.ye@xxxxxxxxxxxxx>
>
> Currently usbnet_disconnect() unanchors and frees all deferred URBs
> using usb_scuttle_anchored_urbs(), which does not free urb->context,
> causing a memory leak as reported by syzbot.
>
> Use a usb_get_from_anchor() while loop instead, similar to what we did
> in commit 19cfe912c37b ("Bluetooth: btusb: Fix memory leak in
> play_deferred"). Also free urb->sg.
>
> [...]

Here is the summary with links:
- [net] usbnet: Fix memory leak in usbnet_disconnect()
https://git.kernel.org/netdev/net/c/a43206156263

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html