Skip to content

Commit dc06fe5

Browse files
committed
Merge tag 'rtc-5.9' of git://git.kernel.org/pub/scm/linux/kernel/git/abelloni/linux
Pull RTC updates from Alexandre Belloni: "Not much this cycle - mostly non urgent driver fixes: - ds1374: use watchdog core - pcf2127: add alarm and pcf2129 support" * tag 'rtc-5.9' of git://git.kernel.org/pub/scm/linux/kernel/git/abelloni/linux: rtc: pcf2127: fix alarm handling rtc: pcf2127: add alarm support rtc: pcf2127: add pca2129 device id rtc: max77686: Fix wake-ups for max77620 rtc: ds1307: provide an indication that the watchdog has fired rtc: ds1374: remove unused define rtc: ds1374: fix RTC_DRV_DS1374_WDT dependencies rtc: cleanup obsolete comment about struct rtc_class_ops rtc: pl031: fix set_alarm by adding back call to alarm_irq_enable rtc: ds1374: wdt: Use watchdog core for watchdog part rtc: Replace HTTP links with HTTPS ones rtc: goldfish: Enable interrupt in set_alarm() when necessary rtc: max77686: Do not allow interrupt to fire before system resume rtc: imxdi: fix trivial typos rtc: cpcap: fix range
2 parents 7c2a69f + 2700641 commit dc06fe5

File tree

15 files changed

+244
-218
lines changed

15 files changed

+244
-218
lines changed

Documentation/devicetree/bindings/rtc/trivial-rtc.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@ properties:
5252
- nxp,pcf2127
5353
# Real-time clock
5454
- nxp,pcf2129
55+
# Real-time clock
56+
- nxp,pca2129
5557
# Real-time Clock Module
5658
- pericom,pt7c4338
5759
# I2C bus SERIAL INTERFACE REAL-TIME CLOCK IC

drivers/rtc/Kconfig

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,8 @@ config RTC_DRV_DS1374
281281

282282
config RTC_DRV_DS1374_WDT
283283
bool "Dallas/Maxim DS1374 watchdog timer"
284-
depends on RTC_DRV_DS1374
284+
depends on RTC_DRV_DS1374 && WATCHDOG
285+
select WATCHDOG_CORE
285286
help
286287
If you say Y here you will get support for the
287288
watchdog timer in the Dallas Semiconductor DS1374

drivers/rtc/rtc-ab-b5ze-s3.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
* Detailed datasheet of the chip is available here:
99
*
10-
* http://www.abracon.com/realtimeclock/AB-RTCMC-32.768kHz-B5ZE-S3-Application-Manual.pdf
10+
* https://www.abracon.com/realtimeclock/AB-RTCMC-32.768kHz-B5ZE-S3-Application-Manual.pdf
1111
*
1212
* This work is based on ISL12057 driver (drivers/rtc/rtc-isl12057.c).
1313
*

drivers/rtc/rtc-bq32k.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
* Copyright (C) 2014 Pavel Machek <pavel@denx.de>
77
*
88
* You can get hardware description at
9-
* http://www.ti.com/lit/ds/symlink/bq32000.pdf
9+
* https://www.ti.com/lit/ds/symlink/bq32000.pdf
1010
*/
1111

1212
#include <linux/module.h>

drivers/rtc/rtc-cpcap.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ static int cpcap_rtc_probe(struct platform_device *pdev)
261261
return PTR_ERR(rtc->rtc_dev);
262262

263263
rtc->rtc_dev->ops = &cpcap_rtc_ops;
264-
rtc->rtc_dev->range_max = (1 << 14) * SECS_PER_DAY - 1;
264+
rtc->rtc_dev->range_max = (timeu64_t) (DAY_MASK + 1) * SECS_PER_DAY - 1;
265265

266266
err = cpcap_get_vendor(dev, rtc->regmap, &rtc->vendor);
267267
if (err)

drivers/rtc/rtc-ds1307.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1668,6 +1668,8 @@ static const struct watchdog_ops ds1388_wdt_ops = {
16681668
static void ds1307_wdt_register(struct ds1307 *ds1307)
16691669
{
16701670
struct watchdog_device *wdt;
1671+
int err;
1672+
int val;
16711673

16721674
if (ds1307->type != ds_1388)
16731675
return;
@@ -1676,6 +1678,10 @@ static void ds1307_wdt_register(struct ds1307 *ds1307)
16761678
if (!wdt)
16771679
return;
16781680

1681+
err = regmap_read(ds1307->regmap, DS1388_REG_FLAG, &val);
1682+
if (!err && val & DS1388_BIT_WF)
1683+
wdt->bootstatus = WDIOF_CARDRESET;
1684+
16791685
wdt->info = &ds1388_wdt_info;
16801686
wdt->ops = &ds1388_wdt_ops;
16811687
wdt->timeout = 99;

0 commit comments

Comments
 (0)