linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] Bluetooth: btmrvl_sdio: Fix wakeup source leaks on device unbind
@ 2025-04-06 20:10 Krzysztof Kozlowski
  2025-04-06 20:10 ` [PATCH 2/2] Bluetooth: btmtksdio: " Krzysztof Kozlowski
  2025-04-10 17:10 ` [PATCH 1/2] Bluetooth: btmrvl_sdio: " patchwork-bot+bluetooth
  0 siblings, 2 replies; 3+ messages in thread
From: Krzysztof Kozlowski @ 2025-04-06 20:10 UTC (permalink / raw)
  To: Marcel Holtmann, Luiz Augusto von Dentz, Matthias Brugger,
	AngeloGioacchino Del Regno, linux-bluetooth, linux-kernel,
	linux-arm-kernel, linux-mediatek
  Cc: Krzysztof Kozlowski

Device can be unbound or probe can fail, so driver must also release
memory for the wakeup source.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/bluetooth/btmrvl_sdio.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/bluetooth/btmrvl_sdio.c b/drivers/bluetooth/btmrvl_sdio.c
index 07cd308f7abf..93932a0d8625 100644
--- a/drivers/bluetooth/btmrvl_sdio.c
+++ b/drivers/bluetooth/btmrvl_sdio.c
@@ -100,7 +100,9 @@ static int btmrvl_sdio_probe_of(struct device *dev,
 			}
 
 			/* Configure wakeup (enabled by default) */
-			device_init_wakeup(dev, true);
+			ret = devm_device_init_wakeup(dev);
+			if (ret)
+				return dev_err_probe(dev, ret, "Failed to init wakeup\n");
 		}
 	}
 
-- 
2.45.2



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [PATCH 2/2] Bluetooth: btmtksdio: Fix wakeup source leaks on device unbind
  2025-04-06 20:10 [PATCH 1/2] Bluetooth: btmrvl_sdio: Fix wakeup source leaks on device unbind Krzysztof Kozlowski
@ 2025-04-06 20:10 ` Krzysztof Kozlowski
  2025-04-10 17:10 ` [PATCH 1/2] Bluetooth: btmrvl_sdio: " patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: Krzysztof Kozlowski @ 2025-04-06 20:10 UTC (permalink / raw)
  To: Marcel Holtmann, Luiz Augusto von Dentz, Matthias Brugger,
	AngeloGioacchino Del Regno, linux-bluetooth, linux-kernel,
	linux-arm-kernel, linux-mediatek
  Cc: Krzysztof Kozlowski

Device can be unbound or probe can fail, so driver must also release
memory for the wakeup source.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/bluetooth/btmtksdio.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/bluetooth/btmtksdio.c b/drivers/bluetooth/btmtksdio.c
index edd5eead1e93..566c136e83bf 100644
--- a/drivers/bluetooth/btmtksdio.c
+++ b/drivers/bluetooth/btmtksdio.c
@@ -1410,7 +1410,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");
 
-- 
2.45.2



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH 1/2] Bluetooth: btmrvl_sdio: Fix wakeup source leaks on device unbind
  2025-04-06 20:10 [PATCH 1/2] Bluetooth: btmrvl_sdio: Fix wakeup source leaks on device unbind Krzysztof Kozlowski
  2025-04-06 20:10 ` [PATCH 2/2] Bluetooth: btmtksdio: " Krzysztof Kozlowski
@ 2025-04-10 17:10 ` patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+bluetooth @ 2025-04-10 17:10 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: marcel, luiz.dentz, matthias.bgg, angelogioacchino.delregno,
	linux-bluetooth, linux-kernel, linux-arm-kernel, linux-mediatek

Hello:

This series was applied to bluetooth/bluetooth-next.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Sun,  6 Apr 2025 22:10:16 +0200 you wrote:
> Device can be unbound or probe can fail, so driver must also release
> memory for the wakeup source.
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  drivers/bluetooth/btmrvl_sdio.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)

Here is the summary with links:
  - [1/2] Bluetooth: btmrvl_sdio: Fix wakeup source leaks on device unbind
    https://git.kernel.org/bluetooth/bluetooth-next/c/e760c4024eae
  - [2/2] Bluetooth: btmtksdio: Fix wakeup source leaks on device unbind
    https://git.kernel.org/bluetooth/bluetooth-next/c/0be454533788

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-04-10 18:00 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-04-06 20:10 [PATCH 1/2] Bluetooth: btmrvl_sdio: Fix wakeup source leaks on device unbind Krzysztof Kozlowski
2025-04-06 20:10 ` [PATCH 2/2] Bluetooth: btmtksdio: " Krzysztof Kozlowski
2025-04-10 17:10 ` [PATCH 1/2] Bluetooth: btmrvl_sdio: " patchwork-bot+bluetooth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).