* [PATCH] net: wwan: t7xx: Fix the ACPI memory leak
@ 2022-11-22 12:19 Hanjun Guo
2022-11-24 8:20 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: Hanjun Guo @ 2022-11-22 12:19 UTC (permalink / raw)
To: Chandrashekar Devegowda, Chiranjeevi Rapolu, Liu Haijun,
M Chetan Kumar, Ricardo Martinez, Loic Poulain, Sergey Ryazanov,
David S. Miller
Cc: linux-kernel, netdev, Hanjun Guo
The ACPI buffer memory (buffer.pointer) should be freed as the
buffer is not used after acpi_evaluate_object(), free it to
prevent memory leak.
Fixes: 13e920d93e37 ("net: wwan: t7xx: Add core components")
Signed-off-by: Hanjun Guo <guohanjun@huawei.com>
---
drivers/net/wwan/t7xx/t7xx_modem_ops.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/net/wwan/t7xx/t7xx_modem_ops.c b/drivers/net/wwan/t7xx/t7xx_modem_ops.c
index 3458af3..7d0f5e4 100644
--- a/drivers/net/wwan/t7xx/t7xx_modem_ops.c
+++ b/drivers/net/wwan/t7xx/t7xx_modem_ops.c
@@ -165,6 +165,8 @@ static int t7xx_acpi_reset(struct t7xx_pci_dev *t7xx_dev, char *fn_name)
return -EFAULT;
}
+ kfree(buffer.pointer);
+
#endif
return 0;
}
--
1.7.12.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] net: wwan: t7xx: Fix the ACPI memory leak
2022-11-22 12:19 [PATCH] net: wwan: t7xx: Fix the ACPI memory leak Hanjun Guo
@ 2022-11-24 8:20 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2022-11-24 8:20 UTC (permalink / raw)
To: Hanjun Guo
Cc: chandrashekar.devegowda, chiranjeevi.rapolu, haijun.liu,
m.chetan.kumar, ricardo.martinez, loic.poulain, ryazanov.s.a,
davem, linux-kernel, netdev
Hello:
This patch was applied to netdev/net.git (master)
by Paolo Abeni <pabeni@redhat.com>:
On Tue, 22 Nov 2022 20:19:40 +0800 you wrote:
> The ACPI buffer memory (buffer.pointer) should be freed as the
> buffer is not used after acpi_evaluate_object(), free it to
> prevent memory leak.
>
> Fixes: 13e920d93e37 ("net: wwan: t7xx: Add core components")
> Signed-off-by: Hanjun Guo <guohanjun@huawei.com>
>
> [...]
Here is the summary with links:
- net: wwan: t7xx: Fix the ACPI memory leak
https://git.kernel.org/netdev/net/c/08e8a949f684
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2022-11-24 8:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-22 12:19 [PATCH] net: wwan: t7xx: Fix the ACPI memory leak Hanjun Guo
2022-11-24 8:20 ` patchwork-bot+netdevbpf
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).