[PATCH] rtc: bd70528: properly enable wakeup

From: Andreas Kemnade

Date: Thu Sep 10 2026 - 06:17:32 EST


Wakeup on RTC alarm now only accidentially works when wakeup for the power
button connected to the same PMIC is also enabled. Fix that by properly
specifying the wakeup irq.

Signed-off-by: Andreas Kemnade <andreas@xxxxxxxxxxxx>
---
drivers/rtc/rtc-bd70528.c | 2 ++
1 file changed, 2 insertions(+)

diff --git a/drivers/rtc/rtc-bd70528.c b/drivers/rtc/rtc-bd70528.c
index 482810b61495d..dc86882562abd 100644
--- a/drivers/rtc/rtc-bd70528.c
+++ b/drivers/rtc/rtc-bd70528.c
@@ -11,6 +11,7 @@
#include <linux/module.h>
#include <linux/of.h>
#include <linux/platform_device.h>
+#include <linux/pm_wakeirq.h>
#include <linux/regmap.h>
#include <linux/rtc.h>

@@ -320,6 +321,7 @@ static int bd70528_probe(struct platform_device *pdev)

device_set_wakeup_capable(&pdev->dev, true);
device_wakeup_enable(&pdev->dev);
+ devm_pm_set_wake_irq(&pdev->dev, irq);

rtc = devm_rtc_allocate_device(&pdev->dev);
if (IS_ERR(rtc)) {
--
2.47.3