rtc again...

Benjamin Herrenschmidt bh40 at calva.net
Thu Aug 10 03:04:35 EST 2000


>> Ok. Then for this to work, we need to slightly change the boot code not
>> to call simply ppc_md.get_rtc_time(), but to also adjust it on pmac using
>> the pram timezone. That means adding a new ppc_md.fixup_time() used only
>> at boot, or adding a "fixup" parameter to ppc_mc.get_rtc_time() set to 0
>> in normal cases and to 1 on first call during boot.
>
>Or let ppc_md.time_init() return offset between ppc_md.get_rtc_time()
>value and UTC and use the offset in time_init() as I proposed
>previously...

Yes, that would work. But when the offset is non-NULL we must also make
sure we call do_settimeofday() to disable the warp hack in kernel/time.c

Saving the timezone value to xpram is another issue. It could be done
from userland but we currently don't have userland tool that properly
access the xpram portion of the nvram. I did plan to add some ioctls to /
dev/nvram for it to return the location of the various nvram partitions,
looks like it will be time to actually implement them... Also, the
userland tool will have to be written...


** Sent via the linuxppc-dev mail list. See http://lists.linuxppc.org/





More information about the Linuxppc-dev mailing list