-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for save/restore system clock from file #796
Conversation
@wkz pretesting Finit patches, I'll make sure to add a ChangeLog update and a better PR description tomorrow. |
The RTC in the CN913x series does not have any "valid" bit, and this board (all revs) does not have any backup power connected, so it will return garbage values after every vold boot. It was therefore decided to disable the RTC completely and set system time manually, or using an NTP client. This way any time skips would only ever be forward, never backwards. Signed-off-by: Joachim Wiberg <[email protected]>
Signed-off-by: Joachim Wiberg <[email protected]>
Signed-off-by: Joachim Wiberg <[email protected]>
This fixes an annoying problem with `make run` when set to boot with a qcow2 disk image. By default the disk image was recreated every time the qemu.sh script was called. Also, add image check to enforce regen if broken. Signed-off-by: Joachim Wiberg <[email protected]>
Creating/Recreating the qcow2 image now logs to stdout, as does the check using qemu-img, which looks funny in raw mode. So let's delay the start of raw mode until just before starting qemu. Signed-off-by: Joachim Wiberg <[email protected]>
Signed-off-by: Joachim Wiberg <[email protected]>
Signed-off-by: Joachim Wiberg <[email protected]>
The string variable handling in configuring Finit did not follow the Buildroot best practises. This patch adds stripping quotes from all string variables before adding them as configure arguments. This fixes issue with, e.g., this sneaky bastard: configure --with-rtc-date=""2024-10-12 12:34:56"" Signed-off-by: Joachim Wiberg <[email protected]>
e50fa66
to
05cb932
Compare
Backport support for saving and restoring system time from a file on systems with broken RTC that reset to the future. With this support a system can be sure time only ever moves forward. Fix #794 Signed-off-by: Joachim Wiberg <[email protected]>
Signed-off-by: Joachim Wiberg <[email protected]>
Signed-off-by: Joachim Wiberg <[email protected]>
@mattiaswal maybe you can focus your review on the non RTC-related changes? (If you're pressed for time, that is.) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
Description
This PR mainly addresses issues with malfunctioning RTC devices. A few minor "infra" changes have also been included, listed at the end:
Major:
Minor:
mnt
script, add missing-n
to testqemu.sh -c
when disk image is selectedqemu.sh
is startedqemu.sh
qemu.sh
Checklist
Tick relevant boxes, this PR is-a or has-a: