[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20200306015703.42101-2-alexandre.belloni@bootlin.com>
Date: Fri, 6 Mar 2020 02:57:02 +0100
From: Alexandre Belloni <alexandre.belloni@...tlin.com>
To: Alessandro Zummo <a.zummo@...ertech.it>,
Alexandre Belloni <alexandre.belloni@...tlin.com>
Cc: linux-rtc@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH 2/3] rtc: cpcap: set range
The CPCAP rtc is a 14bit day counter plus a 17bit seconds counter.
Note that this failed on Nov 10 2014 so it is very likely this driver as
never been used since.
Signed-off-by: Alexandre Belloni <alexandre.belloni@...tlin.com>
---
drivers/rtc/rtc-cpcap.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/rtc/rtc-cpcap.c b/drivers/rtc/rtc-cpcap.c
index 35f0717661b3..38f949730b1b 100644
--- a/drivers/rtc/rtc-cpcap.c
+++ b/drivers/rtc/rtc-cpcap.c
@@ -261,6 +261,7 @@ static int cpcap_rtc_probe(struct platform_device *pdev)
return PTR_ERR(rtc->rtc_dev);
rtc->rtc_dev->ops = &cpcap_rtc_ops;
+ rtc->rtc_dev->range_max = (1 << 14) * SECS_PER_DAY - 1;
err = cpcap_get_vendor(dev, rtc->regmap, &rtc->vendor);
if (err)
--
2.24.1
Powered by blists - more mailing lists