mirror of
https://github.com/troglobit/finit.git
synced 2026-10-19 11:09:35 +00:00
Remove optional --directisa call to hwclock, this is the default anyway.
This is a followup to Olivier Blin's patch from 88ffb93 in that it
applies the same patch to finit-mod.c that is already in finit.c, or
finit-alt.c as it was called then.
Also, the optional --directisa argument to hwclock is not necessary.
The hwclock utility has a built-in fallback to use excplicit I/O over
the /dev/rtc in case the latter does not exist. See the hwclock(8) man
page for more information on this.
Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
1 parent
5816c9cab9
commit
e2c4a6ceaf
4 files changed
+4
-30
No files matched your search
@@ -77,12 +77,6 @@ THE SOFTWARE.
|
||||
#define USE_ETC_RESOLVCONF_RUN
|
||||
#endif
|
||||
|
||||
#ifdef DIRECTISA
|
||||
#define HWCLOCK_DIRECTISA " --directisa"
|
||||
#else
|
||||
#define HWCLOCK_DIRECTISA
|
||||
#endif
|
||||
|
||||
|
||||
/* From sysvinit */
|
||||
/* Set a signal handler. */
|
||||
@@ -397,7 +391,7 @@ int main()
|
||||
*/
|
||||
_d("adjust clock");
|
||||
#ifndef NO_HCTOSYS
|
||||
system("/sbin/hwclock --hctosys" HWCLOCK_DIRECTISA);
|
||||
system("/sbin/hwclock --hctosys");
|
||||
#endif
|
||||
|
||||
/*
|
||||
@@ -590,7 +584,7 @@ void shutdown(int sig)
|
||||
sleep(2);
|
||||
|
||||
system("/usr/sbin/alsactl store > /dev/null 2>&1");
|
||||
system("/sbin/hwclock --systohc" HWCLOCK_DIRECTISA);
|
||||
system("/sbin/hwclock --systohc");
|
||||
|
||||
kill(-1, SIGKILL);
|
||||
|
||||
|
||||
Reference in new issue
Block a user