]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - src/initscripts/system/setclock
initscripts: load RTC module (RX8025) for Ten64 board
[people/pmueller/ipfire-2.x.git] / src / initscripts / system / setclock
index b566eb7166ec78a44a28477257bb1c7e2180b284..963507f9ace48e51c0d696d5c5aa28dfe7f5d249 100644 (file)
@@ -29,6 +29,14 @@ case ${1} in
 
                boot_mesg "Setting system clock..."
 
+               FDT_COMPAT_FILE="/sys/firmware/devicetree/base/compatible"
+               # RTC may not be automatically loaded on some
+               # non-x86 machines
+               if [ -f "${FDT_COMPAT_FILE}" ] && \
+                       ( grep -q "traverse,ten64" "${FDT_COMPAT_FILE}" ); then
+                       modprobe rtc-rx8025
+               fi
+
                # udev not create the rtc symlink if rtc is in the kernel
                if [ ! -e /dev/rtc ]; then
                        if [ -e /dev/rtc0 ]; then