diff options
author | 2025-04-06 21:50:10 +0200 | |
---|---|---|
committer | 2025-05-23 08:49:07 +0100 | |
commit | 2c8294c9aaa0f799c440d10e3582ef410be881bd (patch) | |
tree | d33844b4a64ceedb15a1776509567ed706ae93fd | |
parent | mfd: 88pm886: Fix wakeup source leaks on device unbind (diff) | |
download | linux-rng-2c8294c9aaa0f799c440d10e3582ef410be881bd.tar.xz linux-rng-2c8294c9aaa0f799c440d10e3582ef410be881bd.zip |
mfd: as3722: Fix wakeup source leaks on device unbind
Device can be unbound, so driver must also release memory for the wakeup
source.
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20250406-mfd-device-wakekup-leak-v1-2-318e14bdba0a@linaro.org
Signed-off-by: Lee Jones <lee@kernel.org>
Diffstat (limited to '')
-rw-r--r-- | drivers/mfd/as3722.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mfd/as3722.c b/drivers/mfd/as3722.c index 6c0d89b0c7e3..7ab6fcc9c27c 100644 --- a/drivers/mfd/as3722.c +++ b/drivers/mfd/as3722.c @@ -394,7 +394,9 @@ static int as3722_i2c_probe(struct i2c_client *i2c) return ret; } - device_init_wakeup(as3722->dev, true); + ret = devm_device_init_wakeup(as3722->dev); + if (ret) + return dev_err_probe(as3722->dev, ret, "Failed to init wakeup\n"); dev_dbg(as3722->dev, "AS3722 core driver initialized successfully\n"); return 0; |