From: Alexandre Belloni <alexandre.belloni@bootlin.com>
To: Corentin Labbe <clabbe.montjoie@gmail.com>
Cc: a.zummo@towertech.it, linux-rtc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: rtc: rtc-m48t59: rtc-m48t59.0: IRQ index 0 not found
Date: Thu, 11 Mar 2021 09:57:57 +0100 [thread overview]
Message-ID: <YEnblWV1VWJJHtyv@piout.net> (raw)
In-Reply-To: <YEiXHjIrXfjkrv5U@Red>
Hello,
On 10/03/2021 10:53:34+0100, Corentin Labbe wrote:
> Hello
>
> On my SPARC sunblade 100, I got this:
> [ 13.613727] rtc-m48t59 rtc-m48t59.0: IRQ index 0 not found
> [ 13.805777] rtc-m48t59 rtc-m48t59.0: registered as rtc0
> [ 14.385092] rtc-m48t59 rtc-m48t59.0: setting system clock to 2021-03-01T05:34:33 UTC (1614576873)
>
> The IRQ index 0 message is found after 5.5
>
> Testing rtc via hwclock give:
> hwclock: ioctl(3, RTC_UIE_ON, 0) to /dev/rtc0 failed: Input/output error
> But this hwclock behavior is present also on earlier kernel (tested 4.9.260, 4.19.179 and 4.14.224).
>
> Does this Input/output error is normal ? (I think no)
This is due to 7723f4c5ecdb8d832f049f8483beb0d1081cedf6
Can you try that?
From 55cc33fab5ac9f7e2a97aa7c564e8b35355886d5 Mon Sep 17 00:00:00 2001
From: Alexandre Belloni <alexandre.belloni@bootlin.com>
Date: Thu, 11 Mar 2021 09:48:09 +0100
Subject: [PATCH] rtc: m48t59: use platform_get_irq_optional
The IRQ is optional, avoid the error message by using
platform_get_irq_optional.
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
---
drivers/rtc/rtc-m48t59.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/rtc/rtc-m48t59.c b/drivers/rtc/rtc-m48t59.c
index 1d2e99a70fce..f0f6b9b6daec 100644
--- a/drivers/rtc/rtc-m48t59.c
+++ b/drivers/rtc/rtc-m48t59.c
@@ -421,7 +421,7 @@ static int m48t59_rtc_probe(struct platform_device *pdev)
/* Try to get irq number. We also can work in
* the mode without IRQ.
*/
- m48t59->irq = platform_get_irq(pdev, 0);
+ m48t59->irq = platform_get_irq_optional(pdev, 0);
if (m48t59->irq <= 0)
m48t59->irq = NO_IRQ;
--
2.29.2
--
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
prev parent reply other threads:[~2021-03-11 8:58 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-10 9:53 rtc: rtc-m48t59: rtc-m48t59.0: IRQ index 0 not found Corentin Labbe
2021-03-11 8:57 ` Alexandre Belloni [this message]
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=YEnblWV1VWJJHtyv@piout.net \
--to=alexandre.belloni@bootlin.com \
--cc=a.zummo@towertech.it \
--cc=clabbe.montjoie@gmail.com \
--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;
as well as URLs for NNTP newsgroup(s).