projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cd07ead
)
net: wwan: t7xx: Fix the ACPI memory leak
author
Hanjun Guo
<guohanjun@huawei.com>
Tue, 22 Nov 2022 12:19:40 +0000
(20:19 +0800)
committer
Paolo Abeni
<pabeni@redhat.com>
Thu, 24 Nov 2022 07:54:59 +0000
(08:54 +0100)
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>
Link:
https://lore.kernel.org/r/1669119580-28977-1-git-send-email-guohanjun@huawei.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
drivers/net/wwan/t7xx/t7xx_modem_ops.c
patch
|
blob
|
history
diff --git
a/drivers/net/wwan/t7xx/t7xx_modem_ops.c
b/drivers/net/wwan/t7xx/t7xx_modem_ops.c
index
3458af3
..
7d0f5e4
100644
(file)
--- 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;
}