linux/include
Guenter Roeck 781589e40a rtc: Add support for limited alarm timer offsets
Some alarm timers are based on time offsets, not on absolute times.
In some situations, the amount of time that can be scheduled in the
future is limited. This may result in a refusal to suspend the system,
causing substantial battery drain.

Some RTC alarm drivers remedy the situation by setting the alarm time
to the maximum supported time if a request for an out-of-range timeout
is made. This is not really desirable since it may result in unexpected
early wakeups.

To reduce the impact of this problem, let RTC drivers report the maximum
supported alarm timer offset. The code setting alarm timers can then
decide if it wants to reject setting alarm timers to a larger value, if it
wants to implement recurring alarms until the actually requested alarm
time is met, or if it wants to accept the limited alarm time.

Only introduce the necessary variable into struct rtc_device.
Code to set and use the variable will follow with subsequent patches.

Cc: Brian Norris <briannorris@chromium.org>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20230817225537.4053865-2-linux@roeck-us.net
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
2023-08-27 23:50:22 +02:00
..
acpi More ACPI updates for 6.5-rc1 2023-07-06 22:25:06 -07:00
asm-generic RISC-V Patches for the 6.5 Merge Window, Part 2 2023-07-07 10:07:19 -07:00
clocksource
crypto This update includes the following changes: 2023-06-30 21:27:13 -07:00
drm
dt-bindings Another set of clk driver updates and fixes for the merge window. The 2023-07-04 11:07:45 -07:00
keys
kunit
kvm Common KVM changes for 6.5: 2023-07-01 07:07:55 -04:00
linux rtc: Add support for limited alarm timer offsets 2023-08-27 23:50:22 +02:00
math-emu
media media updates for v6.5-rc1 2023-07-05 10:42:32 -07:00
memory
misc
net Including fixes from bluetooth, bpf and wireguard. 2023-07-05 15:44:45 -07:00
pcmcia
ras
rdma rdma: fix INFINIBAND_USER_ACCESS dependency 2023-07-03 16:55:04 -07:00
rv
scsi SCSI misc on 20230629 2023-06-30 11:57:07 -07:00
soc Including fixes from bluetooth, bpf and wireguard. 2023-07-05 15:44:45 -07:00
sound ASoC: Updates for v6.5 2023-06-26 15:38:02 +02:00
target SCSI misc on 20230629 2023-06-30 11:57:07 -07:00
trace Including fixes from bluetooth, bpf and wireguard. 2023-07-05 15:44:45 -07:00
uapi hardening fixes for v6.5-rc1 2023-07-08 12:08:39 -07:00
ufs SCSI misc on 20230629 2023-06-30 11:57:07 -07:00
vdso
video sticon/parisc: Fix STI console on 64-bit only machines 2023-06-30 17:14:14 +02:00
xen x86: xen: add missing prototypes 2023-06-26 07:47:11 +02:00