On May 12, 2015, at 2:11 AM, Ian Campbell <[email protected]> wrote:
> On Tue, 2015-05-12 at 01:33 -0700, Rick Thomas wrote:
>> On May 6, 2015, at 3:35 AM, Rick Thomas <[email protected]> wrote:
>>
>>>
>>> On May 6, 2015, at 3:27 AM, Ian Campbell <[email protected]> wrote:
>>>
>>>> It would be preferable to test the thing in Sid before the upload to
>>>> jessie-proposed-updates
>>>
>>> I’ll keep an eye out for it.
>>>
>>> But I don’t have one of the cubox models without the battery-backed
>>> RTC, so I won’t be able to test that case. Is there anyone out there
>>> in debian-arm land with an appropriate test box?
>>>
>>> Enjoy!
>>> Rick
It arrived this morning. I’ve got two RTC entries now in /dev. But I’m a bit
confused…
Looking at the boot log with journalctl (see attachment), it appears that the
snvs RTC (i.e. the one without a battery backup) is being found first, and the
_kernel_ is setting system time from it — ignoring /etc/init.d/hwclock.sh
completely.
The pcf8523 RTC (the one with battery backup) is being discovered later, and is
not being used to set the system time at all.
This is exactly the opposite of the behavior I was hoping for.
Well… I thought I was prepared for that by planning to use parameters in
/etc/default/hwclock to tell it which RTC to use when shutting-down or
booting-up. But it appears that those parameters are being ignored.
Looking in /lib/systemd/system/hwclock-save.service (the systemd equivalent of
/etc/init.d/hwclock), I find “ExecStart=/sbin/hwclock -D —systohc” which is
interesting because (1) it invokes a “-D” option which is not documented in
“man hwclock”, (2) it ignores the /etc/default parameters, and (3) it’s only
being done on shutdown/halt/reboot; there’s no corresponding service that gets
run at boot time… Is the RTC driver itself supposed to be doing that, so
there’s no need for sysvinit or systemd to worry about it??? The “setting
system clock” log entry would seem to substantiate that.
So what to do now?
Any constructive suggestions will appreciated.
Rick
root@cube:~# journalctl | egrep 'rtc|clock|date|time'
May 12 20:54:53 cube systemd-journal[167]: Runtime journal is using 5.0M (max
allowed 40.3M, trying to leave 60.5M free of 398.5M available â current limit
40.3M).
May 12 20:54:53 cube systemd-journal[167]: Runtime journal is using 5.0M (max
allowed 40.3M, trying to leave 60.5M free of 398.5M available â current limit
40.3M).
May 12 20:54:53 cube kernel: L2C-310 dynamic clock gating enabled, standby mode
enabled
May 12 20:54:53 cube kernel: Switching to timer-based delay loop, resolution
333ns
May 12 20:54:53 cube kernel: sched_clock: 32 bits at 3000kHz, resolution 333ns,
wraps every 1431655765682ns
May 12 20:54:53 cube kernel: Calibrating delay loop (skipped), value calculated
using timer frequency.. 6.00 BogoMIPS (lpj=12000)
May 12 20:54:53 cube kernel: AppArmor: AppArmor disabled by boot time parameter
May 12 20:54:53 cube kernel: PTP clock support registered
May 12 20:54:53 cube kernel: Switched to clocksource mxc_timer1
May 12 20:54:53 cube kernel: snvs_rtc 20cc034.snvs-rtc-lp: rtc core: registered
20cc034.snvs-rtc-lp as rtc0
May 12 20:54:53 cube kernel: snvs_rtc 20cc034.snvs-rtc-lp: setting system clock
to 2015-05-13 03:54:49 UTC (1431489289)
May 12 20:54:53 cube kernel: imx2-wdt 20bc000.wdog: timeout 60 sec (nowayout=0)
May 12 20:54:53 cube kernel: rtc-pcf8523 2-0068: rtc core: registered
rtc-pcf8523 as rtc1
May 12 20:54:54 cube kernel: [drm] Supports vblank timestamp caching Rev 2
(21.10.2013).
May 12 20:54:54 cube kernel: [drm] No driver support for vblank timestamp query.
May 12 20:54:54 cube kernel: imx-drm display-subsystem: bound imx-ipuv3-crtc.0
(ops ipu_drm_driver_exit [imx_ipuv3_crtc])
May 12 20:54:54 cube kernel: imx-drm display-subsystem: bound imx-ipuv3-crtc.1
(ops ipu_drm_driver_exit [imx_ipuv3_crtc])
May 12 20:54:54 cube kernel: imx-drm display-subsystem: bound imx-ipuv3-crtc.4
(ops ipu_drm_driver_exit [imx_ipuv3_crtc])
May 12 20:54:54 cube kernel: imx-drm display-subsystem: bound imx-ipuv3-crtc.5
(ops ipu_drm_driver_exit [imx_ipuv3_crtc])
May 12 20:54:54 cube kernel: [drm] Cannot find any crtc or sizes - going
1024x768
May 12 20:55:56 cube systemd-journal[167]: Runtime journal is using 5.0M (max
allowed 40.3M, trying to leave 60.5M free of 398.3M available â current limit
40.3M).
May 12 20:55:56 cube adjtimex[356]: Regulating system clock...done.
May 12 20:55:59 cube ntpd[481]: Listening on routing socket on fd #20 for
interface updates
May 12 20:56:03 cube colord[833]: Cannot adopt OID in UCD-SNMP-MIB:
versionUpdateConfig ::= { version 11 }
May 12 20:56:06 cube ntpd[918]: Listening on routing socket on fd #23 for
interface updates
May 12 21:23:02 cube CRON[1236]: (rbthomas) CMD (bash bin/check_cmos_ctime)