aarch64 kernel RTC issues - missing config options

Discussion about U-Boot and the kernel.

aarch64 kernel RTC issues - missing config options

Postby iefbr14 » Wed Feb 09, 2022 1:48 am

Greetings.

I've recently switched my Odroid N2 over to the aarch64 mainline kernel with the linux-aarch64 package.

Unfortunately, there are issues with the real time clock. timedatectl and hwclock commands - they just fail... like the RTC is not avaialable.

Turns out that the kernel config used by the linux-aarch64-5.16.7-2 package is missing a couple config options:

CONFIG_RTC_SYSTOHC=y
CONFIG_RTC_SYSTOHC_DEVICE="rtc0"


I enabled both config options (above), recompiled, and installed the resulting kernel. timedatectl & hwclock working normally again.

For what its worth, the linux-armv-7-5.16.7-1 package (used on my Odroid XU4) DOES contain the above 2 kernel config options -- and of course, the RTC on the XU4 works fine.

I'd submit a pull-request to add the 2 config settings for aarch64, but I have a feeling it'd just be ignored... :cry:

Perhaps a dev would be interested in pursuing the change... or perhaps this post will be useful to somebody else experiencing the same issue with the RTC on their board with the aarch64 kernel.

iefbr14

$this->bbcode_second_pass_code('', '--- config.old 2022-02-08 18:25:32.944995083 -0700
+++ config 2022-02-08 16:19:17.185605661 -0700
@@ -7864,7 +7864,8 @@
CONFIG_RTC_CLASS=y
CONFIG_RTC_HCTOSYS=y
CONFIG_RTC_HCTOSYS_DEVICE="rtc0"
-# CONFIG_RTC_SYSTOHC is not set
+CONFIG_RTC_SYSTOHC=y
+CONFIG_RTC_SYSTOHC_DEVICE="rtc0"
# CONFIG_RTC_DEBUG is not set
CONFIG_RTC_NVMEM=y
')
iefbr14
 
Posts: 10
Joined: Sat Sep 16, 2017 4:09 am

Re: aarch64 kernel RTC issues - missing config options

Postby graysky » Thu Feb 10, 2022 12:49 pm

The update to 5.16.8-1 should fix this.
graysky
Developer
 
Posts: 1723
Joined: Sun Jun 26, 2011 6:56 am
Location: /run/user/1000


Return to U-Boot/Kernel

Who is online

Users browsing this forum: No registered users and 1 guest