From: alexandre.belloni@bootlin.com
To: Johan Hovold <johan+linaro@kernel.org>,
Alexandre Belloni <alexandre.belloni@bootlin.com>
Cc: linux-arm-msm@vger.kernel.org, linux-rtc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: [PATCH] rtc: pm8xxx: switch to devm_device_init_wakeup
Date: Mon, 17 Mar 2025 12:13:11 +0100 [thread overview]
Message-ID: <20250317111312.1518349-1-alexandre.belloni@bootlin.com> (raw)
From: Alexandre Belloni <alexandre.belloni@bootlin.com>
Switch to devm_device_init_wakeup to avoid a possible memory leak as wakeup
is never disabled.
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
---
drivers/rtc/rtc-pm8xxx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/rtc/rtc-pm8xxx.c b/drivers/rtc/rtc-pm8xxx.c
index c6241a0c26e9..70cbac76147b 100644
--- a/drivers/rtc/rtc-pm8xxx.c
+++ b/drivers/rtc/rtc-pm8xxx.c
@@ -647,7 +647,7 @@ static int pm8xxx_rtc_probe(struct platform_device *pdev)
if (rc)
return rc;
- device_init_wakeup(&pdev->dev, true);
+ devm_device_init_wakeup(&pdev->dev);
} else {
clear_bit(RTC_FEATURE_ALARM, rtc_dd->rtc->features);
}
--
2.48.1
next reply other threads:[~2025-03-17 11:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-17 11:13 alexandre.belloni [this message]
2025-03-17 11:58 ` Johan Hovold
2025-03-17 13:34 ` Alexandre Belloni
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250317111312.1518349-1-alexandre.belloni@bootlin.com \
--to=alexandre.belloni@bootlin.com \
--cc=johan+linaro@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rtc@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®