From: Krzysztof Kozlowski Date: Sun, 6 Apr 2025 20:10:17 +0000 (+0200) Subject: Bluetooth: btmtksdio: Fix wakeup source leaks on device unbind X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=ee3e4209e66d44180a41d5ca7271361a2a28fccf;p=users%2Fjedix%2Flinux-maple.git Bluetooth: btmtksdio: Fix wakeup source leaks on device unbind Device can be unbound or probe can fail, so driver must also release memory for the wakeup source. Signed-off-by: Krzysztof Kozlowski Signed-off-by: Luiz Augusto von Dentz --- diff --git a/drivers/bluetooth/btmtksdio.c b/drivers/bluetooth/btmtksdio.c index 1d26207b2ba70..c16a3518b8ffa 100644 --- a/drivers/bluetooth/btmtksdio.c +++ b/drivers/bluetooth/btmtksdio.c @@ -1414,7 +1414,7 @@ static int btmtksdio_probe(struct sdio_func *func, */ pm_runtime_put_noidle(bdev->dev); - err = device_init_wakeup(bdev->dev, true); + err = devm_device_init_wakeup(bdev->dev); if (err) bt_dev_err(hdev, "failed to initialize device wakeup");