aboutsummaryrefslogtreecommitdiff
path: root/init.d/hwclock.in
diff options
context:
space:
mode:
Diffstat (limited to 'init.d/hwclock.in')
-rw-r--r--init.d/hwclock.in10
1 files changed, 8 insertions, 2 deletions
diff --git a/init.d/hwclock.in b/init.d/hwclock.in
index 2cd1ef31..d28ac850 100644
--- a/init.d/hwclock.in
+++ b/init.d/hwclock.in
@@ -30,6 +30,7 @@ fi
depend()
{
provide clock
+ want modules
if yesno $clock_adjfile; then
use root
else
@@ -81,7 +82,7 @@ get_noadjfile()
start()
{
- local retval=0 errstr=""
+ local retval=0 errstr="" modname
setupopts
if [ -z "$utc_cmd" ]; then
@@ -96,7 +97,12 @@ start()
[ -e "$rtc" ] && break
done
if [ ! -e "${rtc}" ]; then
- modprobe -q rtc-cmos || modprobe -q rtc || modprobe -q genrtc
+ for x in rtc-cmos rtc genrtc; do
+ modprobe -q $x && modname=$x && break
+ done
+ [ -n "$modname" ] &&
+ ewarn "The $modname module needs to be configured in \
+ @SYSCONFDIR@/conf.d/modules or built in."
fi
fi