Skip to content

Commit 882c5e5

Browse files
rtc: da9063: set uie_unsupported when relevant
The DA9063AD doesn't support alarms on any seconds and its granularity is the minute. Set uie_unsupported in that case. Reported-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Reported-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Tested-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: Steve Twiss <stwiss.opensource@diasemi.com> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
1 parent 22e7d51 commit 882c5e5

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

drivers/rtc/rtc-da9063.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -480,6 +480,13 @@ static int da9063_rtc_probe(struct platform_device *pdev)
480480
da9063_data_to_tm(data, &rtc->alarm_time, rtc);
481481
rtc->rtc_sync = false;
482482

483+
/*
484+
* TODO: some models have alarms on a minute boundary but still support
485+
* real hardware interrupts. Add this once the core supports it.
486+
*/
487+
if (config->rtc_data_start != RTC_SEC)
488+
rtc->rtc_dev->uie_unsupported = 1;
489+
483490
irq_alarm = platform_get_irq_byname(pdev, "ALARM");
484491
ret = devm_request_threaded_irq(&pdev->dev, irq_alarm, NULL,
485492
da9063_alarm_event,

0 commit comments

Comments
 (0)