projects
/
linux-2.6-microblaze.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f103b2e
)
hwmon: (xgene-hwmon) Add free before exiting xgene_hwmon_probe
author
Peiwei Hu
<jlu.hpw@foxmail.com>
Tue, 28 Dec 2021 08:59:10 +0000
(16:59 +0800)
committer
Guenter Roeck
<linux@roeck-us.net>
Tue, 28 Dec 2021 16:04:10 +0000
(08:04 -0800)
Call kfifo_free(&ctx->async_msg_fifo) before error exiting
instead of returning directly.
Signed-off-by: Peiwei Hu <jlu.hpw@foxmail.com>
Link:
https://lore.kernel.org/r/tencent_C851C0324431466CBC22D60C5C6AC4A8E808@qq.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/xgene-hwmon.c
patch
|
blob
|
history
diff --git
a/drivers/hwmon/xgene-hwmon.c
b/drivers/hwmon/xgene-hwmon.c
index
30aae86
..
5cde837
100644
(file)
--- a/
drivers/hwmon/xgene-hwmon.c
+++ b/
drivers/hwmon/xgene-hwmon.c
@@
-659,8
+659,10
@@
static int xgene_hwmon_probe(struct platform_device *pdev)
acpi_id = acpi_match_device(pdev->dev.driver->acpi_match_table,
&pdev->dev);
- if (!acpi_id)
- return -EINVAL;
+ if (!acpi_id) {
+ rc = -EINVAL;
+ goto out_mbox_free;
+ }
version = (int)acpi_id->driver_data;