Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

extcon: adc-jack: Fix wakeup source leaks on device unbind

Device can be unbound, so driver must also release memory for the wakeup
source. Do not use devm interface, because it would change the order of
cleanup.

Link: https://lore.kernel.org/lkml/20250501-device-wakeup-leak-extcon-v2-1-7af77802cbea@linaro.org/
Acked-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>

authored by

Krzysztof Kozlowski and committed by
Chanwoo Choi
78b6a991 1b237f19

+1
+1
drivers/extcon/extcon-adc-jack.c
··· 164 164 { 165 165 struct adc_jack_data *data = platform_get_drvdata(pdev); 166 166 167 + device_init_wakeup(&pdev->dev, false); 167 168 free_irq(data->irq, data); 168 169 cancel_work_sync(&data->handler.work); 169 170 }