System time doesn't sync with RTC time on boot

Bug #1952077 reported by Jesse Sung
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Confirmed
Undecided
Dimitri John Ledkov
Focal
Confirmed
Undecided
Dimitri John Ledkov

Bug Description

== Impact ==
Although we have CONFIG_RTC_HCTOSYS enabled and set CONFIG_RTC_HCTOSYS_DEVICE to "rtc0", system time would only be set if the RTC driver is built-in. This may not be an issue on most amd64 systems because CONFIG_RTC_DRV_CMOS is y for amd64, however it is an issue for other architectures since there may not be a proper RTC driver enabled as built-in. Also making every RTC driver that may be used as built-in is not a good option.

== Fix ==
The commit is in mainline since v5.7:

commit f9b2a4d6a5f18e0aaf715206a056565c56889d9f
Author: Steve Muckle <email address hidden>
Date: Wed Nov 6 11:46:25 2019 -0800

    rtc: class: support hctosys from modular RTC drivers

    Due to distribution constraints it may not be possible to statically
    compile the required RTC driver into the kernel.

    Expand RTC_HCTOSYS support to cover all RTC devices (statically compiled
    or not) by checking at the end of RTC device registration whether the
    time should be synced.

    Signed-off-by: Steve Muckle <email address hidden>
    Link: https://<email address hidden>
    Signed-off-by: Alexandre Belloni <email address hidden>

== Risk of Regression ==
It's a clean cherry-pick for v5.4 and looks straight forward so risk should be low.

Jesse Sung (wenchien)
Changed in linux (Ubuntu Focal):
status: New → In Progress
assignee: nobody → Jesse Sung (wenchien)
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1952077

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Jesse Sung (wenchien)
Changed in linux (Ubuntu):
status: Incomplete → In Progress
assignee: nobody → Jesse Sung (wenchien)
Jesse Sung (wenchien)
description: updated
Revision history for this message
Jesse Sung (wenchien) wrote :

The patch was NAKed: https://lists.ubuntu.com/archives/kernel-team/2021-November/126087.html

Change the status back to confirmed.

Changed in linux (Ubuntu):
status: In Progress → Confirmed
Changed in linux (Ubuntu Focal):
status: In Progress → Confirmed
Changed in linux (Ubuntu Focal):
assignee: Jesse Sung (wenchien) → Dimitri John Ledkov (xnox)
Changed in linux (Ubuntu):
assignee: Jesse Sung (wenchien) → Dimitri John Ledkov (xnox)
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.