mirror of
https://github.com/troglobit/finit.git
synced 2026-11-12 16:51:25 +00:00
plugins/hwclock: Use short-form -s/-w -u to work with BusyBox hwclock as well.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
1 parent
3f1c2f6211
commit
c002b5301f
1 file changed
+4
-2
+4
-2
@@ -28,13 +28,15 @@
|
|||||||
static void save(void *UNUSED(arg))
|
static void save(void *UNUSED(arg))
|
||||||
{
|
{
|
||||||
_d("Saving system clock to RTC ...");
|
_d("Saving system clock to RTC ...");
|
||||||
run_interactive("/sbin/hwclock --systohc --utc", "Saving system time (UTC) to RTC");
|
/* -w,--systohc, -u,--utc */
|
||||||
|
run_interactive("/sbin/hwclock -w -u", "Saving system time (UTC) to RTC");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void restore(void *UNUSED(arg))
|
static void restore(void *UNUSED(arg))
|
||||||
{
|
{
|
||||||
_d("Restoring system clock from RTC ...");
|
_d("Restoring system clock from RTC ...");
|
||||||
run_interactive("/sbin/hwclock --hctosys --utc", "Restoring system clock (UTC) from RTC");
|
/* -s,--hctosys, -u,--utc */
|
||||||
|
run_interactive("/sbin/hwclock -s -u", "Restoring system clock (UTC) from RTC");
|
||||||
}
|
}
|
||||||
|
|
||||||
static plugin_t plugin = {
|
static plugin_t plugin = {
|
||||||
|
|||||||
Reference in new issue
Block a user