From: Krzysztof Kozlowski Date: Sun, 6 Apr 2025 19:50:14 +0000 (+0200) Subject: mfd: max8925: Fix wakeup source leaks on device unbind X-Git-Url: http://git.monstr.eu/?a=commitdiff_plain;h=fd37695dae093533d444237c86c3181a7339abb4;p=linux-2.6-microblaze.git mfd: max8925: 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 Link: https://lore.kernel.org/r/20250406-mfd-device-wakekup-leak-v1-6-318e14bdba0a@linaro.org Signed-off-by: Lee Jones --- diff --git a/drivers/mfd/max8925-i2c.c b/drivers/mfd/max8925-i2c.c index 556aea7ec0a0..ab19ff0c7867 100644 --- a/drivers/mfd/max8925-i2c.c +++ b/drivers/mfd/max8925-i2c.c @@ -201,6 +201,7 @@ static void max8925_remove(struct i2c_client *client) struct max8925_chip *chip = i2c_get_clientdata(client); max8925_device_exit(chip); + device_init_wakeup(&client->dev, false); i2c_unregister_device(chip->adc); i2c_unregister_device(chip->rtc); }