]> git.ipfire.org Git - thirdparty/chrony.git/commitdiff
doc: diagnose problem with RTC interrupts on Linux
authorMichael Witten <mfwitten@gmail.com>
Mon, 14 Dec 2020 23:02:00 +0000 (23:02 +0000)
committerMiroslav Lichvar <mlichvar@redhat.com>
Tue, 15 Dec 2020 09:41:53 +0000 (10:41 +0100)
This commit updates the FAQ with a new entry.

chronyd's Linux RTC driver (rtc_linux.c) requires the following ioctl
requests to be functional:

  RTC_UIE_ON
  RTC_UIE_OFF

However, a Linux system's RTC driver does not necessarily implement them,
as noted in these previous commits:

  d66b2f2b2423bfbd3de4d69895024dac7eefb306
  rtc: handle RTCs that don't support interrupts
  Tue Dec 10 17:45:28 2019 +0100

  bff3f51d13c3f41e2ead2cfff5bfe0b8c22ef44a
  rtc: extend check for RTCs that don't support interrupts
  Thu Dec 12 12:50:19 2019 +0100

Fortunately, the Linux kernel can be built with software emulation of
these hardware requests, by enabling the following config variable:

  CONFIG_RTC_INTF_DEV_UIE_EMUL
    Provides an emulation for RTC_UIE if the underlying rtc chip
    driver does not expose RTC_UIE ioctls. Those requests generate
    once-per-second update interrupts, used for synchronization.

    The emulation code will read the time from the hardware
    clock several times per second, please enable this option
    only if you know that you really need it.

This commit records these facts for the benefit of the user.

doc/faq.adoc

index 9d2c109bd10b4931bf067cb9ab6137350d5e6709..bf9d277913a3c436637e506be8b9707a81482969 100644 (file)
@@ -597,6 +597,19 @@ things
 
 Some other program running on the system might be using the device.
 
+=== When I start `chronyd`, the log says `Could not enable RTC interrupt : Invalid argument` (or it may say `disable`)
+
+Your real-time clock hardware might not support the required ioctl requests:
+
+* `RTC_UIE_ON`
+* `RTC_UIE_OFF`
+
+A possible solution could be to build the Linux kernel with support for software
+emulation instead; try enabling the following configuration option when building
+the Linux kernel:
+
+* `CONFIG_RTC_INTF_DEV_UIE_EMUL`
+
 === What if my computer does not have an RTC or backup battery?
 
 In this case you can still use the `-s` option to set the system clock to the