[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <80637186-e3ef-14c1-78e5-bfa6deec595a@linaro.org>
Date: Mon, 6 Jun 2022 12:46:08 +0200
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Xiaohui Zhang <ruc_zhangxiaohui@....com>,
"David S . Miller" <davem@...emloft.net>, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/1] nfc: nfcmrvl: Fix memory leak in
nfcmrvl_play_deferred
On 05/06/2022 10:14, Xiaohui Zhang wrote:
> From: xiaohuizhang98 <ruc_zhangxiaohui@....com>
>
> We detected a suspected bug with our code clone detection tool.
>
> Similar to the handling of play_deferred in commit 19cfe912c37b
> ("Bluetooth: btusb: Fix memory leak in play_deferred"), we thought
> a patch might be needed here as well.
>
> Currently usb_submit_urb is called directly to submit deferred tx
> urbs after unanchor them.
>
> So the usb_giveback_urb_bh would failed to unref it in usb_unanchor_urb
> and cause memory leak.
>
> Put those urbs in tx_anchor to avoid the leak, and also fix the error
> handling.
>
> Signed-off-by: xiaohuizhang98 <ruc_zhangxiaohui@....com>
This name still does not match your name used in email.
Best regards,
Krzysztof
Powered by blists - more mailing lists