diff options
author | Roy Marples <roy@marples.name> | 2008-01-04 12:50:04 +0000 |
---|---|---|
committer | Roy Marples <roy@marples.name> | 2008-01-04 12:50:04 +0000 |
commit | 3be23bc02d30bc415e5ae3f1bc167280d9fde26e (patch) | |
tree | c2238d5a856ecd4941fa996786017719f6820ff6 | |
parent | 455a9105a87bb69c103e06f290e1ba92b32bb6e6 (diff) |
Instead of mirroring correct output, state that we're not running because of RC_SYS.
-rwxr-xr-x | init.d.Linux/clock | 44 | ||||
-rwxr-xr-x | init.d.Linux/consolefont | 5 | ||||
-rwxr-xr-x | init.d.Linux/keymaps | 3 |
3 files changed, 29 insertions, 23 deletions
diff --git a/init.d.Linux/clock b/init.d.Linux/clock index 1c33e00d..a29e11b7 100755 --- a/init.d.Linux/clock +++ b/init.d.Linux/clock @@ -79,22 +79,26 @@ start() { local retval=0 errstr="" setupopts + if [ -z "${utc_cmd}" ]; then + ewarn "Not setting clock for ${utc} system" + return 0 + fi + ebegin "Setting system clock using the hardware clock [${utc}]" - if [ -n "${utc_cmd}" ]; then - if [ -e /proc/modules -a ! -e /dev/rtc ]; then - modprobe -q rtc || modprobe -q genrtc - fi + if [ -e /proc/modules -a ! -e /dev/rtc ]; then + modprobe -q rtc || modprobe -q genrtc + fi - # Since hwclock always exit's with a 0, need to check its output. - if [ -e /etc/adjtime ] && yesno ${clock_adjfile}; then - errstr="$(hwclock --adjust ${utc_cmd} 2>&1 >/dev/null)" - fi - # If setting UTC, don't bother to run hwclock when first booting - # as that's the default - if [ "${PREVLEVEL}" != "N" -o "${utc_cmd}" != "--utc" -o -n "${clock_args}" ]; then - errstr="${errstr}$(hwclock --hctosys ${utc_cmd} ${clock_args} 2>&1 >/dev/null)" - fi + # Since hwclock always exit's with a 0, need to check its output. + if [ -e /etc/adjtime ] && yesno ${clock_adjfile}; then + errstr="$(hwclock --adjust ${utc_cmd} 2>&1 >/dev/null)" fi + # If setting UTC, don't bother to run hwclock when first booting + # as that's the default + if [ "${PREVLEVEL}" != "N" -o "${utc_cmd}" != "--utc" -o -n "${clock_args}" ]; then + errstr="${errstr}$(hwclock --hctosys ${utc_cmd} ${clock_args} 2>&1 >/dev/null)" + fi + if [ -n "${errstr}" ]; then ewarn "${errstr}" retval=1 @@ -113,16 +117,16 @@ stop() { local retval=0 errstr="" setupopts + [ -z "${utc_cmd}" ] && return 0 + ebegin "Setting hardware clock using the system clock" "[${utc}]" - if [ -n "${utc_cmd}" ]; then - if ! yesno "${clock_adjfile}"; then - # Some implementations don't handle adjustments - if LC_ALL=C hwclock --help | grep -q "\-\-noadjfile"; then - utc_cmd="${utc_cmd} --noadjfile" - fi + if ! yesno "${clock_adjfile}"; then + # Some implementations don't handle adjustments + if LC_ALL=C hwclock --help | grep -q "\-\-noadjfile"; then + utc_cmd="${utc_cmd} --noadjfile" fi - errstr="$(LC_ALL=C hwclock --systohc ${utc_cmd} ${clock_args} 2>&1 >/dev/null)" fi + errstr="$(LC_ALL=C hwclock --systohc ${utc_cmd} ${clock_args} 2>&1 >/dev/null)" if [ -n "${errstr}" ]; then ewarn "${errstr}" retval=1 diff --git a/init.d.Linux/consolefont b/init.d.Linux/consolefont index d2930a15..22e63422 100755 --- a/init.d.Linux/consolefont +++ b/init.d.Linux/consolefont @@ -36,7 +36,10 @@ start() { rm -rf "${RC_LIBDIR}"/console case "${RC_SYS}" in - UML|VPS|XENU) return 0;; + UML|VPS|XENU) + ewarn "Not loading consolefont for ${RC_SYS} systems" + return 0 + ;; esac ttyn=${rc_tty_number:-${RC_TTY_NUMBER:-12}} diff --git a/init.d.Linux/keymaps b/init.d.Linux/keymaps index 28cb9c6d..707e6cfe 100755 --- a/init.d.Linux/keymaps +++ b/init.d.Linux/keymaps @@ -40,8 +40,7 @@ depend() { start() { case "${RC_SYS}" in UML|VPS|XENU) - ebegin "Loading key mappings" - eend 0 + ewarn "Not loading keymaps for ${RC_SYS} systems" return 0 ;; esac |