* spitz: Real time clock?
@ 2005-12-09 21:28 Pavel Machek
2005-12-09 22:39 ` Richard Purdie
0 siblings, 1 reply; 5+ messages in thread
From: Pavel Machek @ 2005-12-09 21:28 UTC (permalink / raw)
To: rpurdie, kernel list
Hi!
Is there driver for real time clock for spitz? I seem to get default
time each time I boot. (And thats bad because means fsck "too much time
since last check, check forced).
Pavel
--
Thanks, Sharp!
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: spitz: Real time clock?
2005-12-09 21:28 spitz: Real time clock? Pavel Machek
@ 2005-12-09 22:39 ` Richard Purdie
2005-12-09 22:53 ` Pavel Machek
0 siblings, 1 reply; 5+ messages in thread
From: Richard Purdie @ 2005-12-09 22:39 UTC (permalink / raw)
To: Pavel Machek; +Cc: kernel list
On Fri, 2005-12-09 at 22:28 +0100, Pavel Machek wrote:
> Is there driver for real time clock for spitz? I seem to get default
> time each time I boot. (And thats bad because means fsck "too much time
> since last check, check forced).
There is but its already included with the kernels you have. It doesn't
survive reboots and this is a limitation of the PXA processor. There's
not a lot we can do about it I'm afraid.
Richard
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: spitz: Real time clock?
2005-12-09 22:39 ` Richard Purdie
@ 2005-12-09 22:53 ` Pavel Machek
2005-12-10 0:19 ` Nicolas Pitre
0 siblings, 1 reply; 5+ messages in thread
From: Pavel Machek @ 2005-12-09 22:53 UTC (permalink / raw)
To: Richard Purdie; +Cc: kernel list
On Pá 09-12-05 22:39:06, Richard Purdie wrote:
> On Fri, 2005-12-09 at 22:28 +0100, Pavel Machek wrote:
> > Is there driver for real time clock for spitz? I seem to get default
> > time each time I boot. (And thats bad because means fsck "too much time
> > since last check, check forced).
>
> There is but its already included with the kernels you have. It doesn't
> survive reboots and this is a limitation of the PXA processor. There's
> not a lot we can do about it I'm afraid.
Ouch, that's bad :-(. So PXA can't keep time properly... could we do
something like storing time on system shutdown and restoring it on
bootup? That way at least time will be monotonic... Ok, that's
userland problem.
Is there way to reboot without "really" rebooting? That would help at
least in my usage case. (Also reboot really does poweroff, not reboot,
but...)
Pavel
--
Thanks, Sharp!
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: spitz: Real time clock?
2005-12-09 22:53 ` Pavel Machek
@ 2005-12-10 0:19 ` Nicolas Pitre
2005-12-10 1:43 ` Richard Purdie
0 siblings, 1 reply; 5+ messages in thread
From: Nicolas Pitre @ 2005-12-10 0:19 UTC (permalink / raw)
To: Pavel Machek; +Cc: Richard Purdie, kernel list
[-- Attachment #1: Type: TEXT/PLAIN, Size: 1236 bytes --]
On Fri, 9 Dec 2005, Pavel Machek wrote:
> On Pá 09-12-05 22:39:06, Richard Purdie wrote:
> > On Fri, 2005-12-09 at 22:28 +0100, Pavel Machek wrote:
> > > Is there driver for real time clock for spitz? I seem to get default
> > > time each time I boot. (And thats bad because means fsck "too much time
> > > since last check, check forced).
> >
> > There is but its already included with the kernels you have. It doesn't
> > survive reboots and this is a limitation of the PXA processor. There's
> > not a lot we can do about it I'm afraid.
>
> Ouch, that's bad :-(. So PXA can't keep time properly...
The RTC count is lost on a hard reset. It survives sleep mode though.
The fact is that PocketPC/WinCE is not meant to be "rebooted" and the
RTC on the PXA was probably designed with that fact. The normal usage
pattern is to go into sleep mode all the time.
> could we do something like storing time on system shutdown and
> restoring it on bootup? That way at least time will be monotonic...
> Ok, that's userland problem.
I'd say so.
> Is there way to reboot without "really" rebooting? That would help at
> least in my usage case.
You should be able to "soft" reboot which will also preserve the RTC
count.
Nicolas
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: spitz: Real time clock?
2005-12-10 0:19 ` Nicolas Pitre
@ 2005-12-10 1:43 ` Richard Purdie
0 siblings, 0 replies; 5+ messages in thread
From: Richard Purdie @ 2005-12-10 1:43 UTC (permalink / raw)
To: Pavel Machek; +Cc: kernel list, Nicolas Pitre
On Fri, 2005-12-09 at 19:19 -0500, Nicolas Pitre wrote:
> The RTC count is lost on a hard reset. It survives sleep mode though.
>
> The fact is that PocketPC/WinCE is not meant to be "rebooted" and the
> RTC on the PXA was probably designed with that fact. The normal usage
> pattern is to go into sleep mode all the time.
Which is the aim of the Zaurus kernel although it doesn't help when
developing...
> > could we do something like storing time on system shutdown and
> > restoring it on bootup? That way at least time will be monotonic...
> > Ok, that's userland problem.
>
> I'd say so.
OpenZaurus/OE did have code to try and do this built into its images.
I'm not sure what its status is at the moment.
> > Is there way to reboot without "really" rebooting? That would help at
> > least in my usage case.
>
> You should be able to "soft" reboot which will also preserve the RTC
> count.
Based on past performance, the bootloader (in ROM) will probably
corrupt/reset the RTC but I'd like to be proved wrong.
Russell posted some rough code to linux-arm-kernel recently that allowed
you load a new kernel in a kexec sort of manner and that is probably the
best bet to preserve the RTC. This functionality would be useful on the
Zaurus in general.
Richard
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2005-12-10 1:43 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-12-09 21:28 spitz: Real time clock? Pavel Machek
2005-12-09 22:39 ` Richard Purdie
2005-12-09 22:53 ` Pavel Machek
2005-12-10 0:19 ` Nicolas Pitre
2005-12-10 1:43 ` Richard Purdie
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®