lkml.org 
[lkml]   [2011]   [Apr]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subjectrtc-twl: catch22 in 2.6.37 and 2.6.38 when clock was never set
Hello,

it just happened here that the rechargeable backup battery for the RTC
on a TPS65950 run out off power, because of some days while the device
wasn't powered.

Afterwards I couldn't read or set the clock with hwclock using a kernel
2.6.37.n or 2.6.38.n.

I don't have a fix, but I think I've analyzed the problem and can offer
a (bad) workaround.

What happens is the following:

When trying to read or set the clock with hwclock, the driver (rtc-twl)
starts an alarm, but the irq for the alarm will never get called. The
result is that a select in hwclock times out (for both operations, read
or set).

Because I had this clock running before, I've got the idea to try one of
those old OMAP-kernels (2.6.32-angstrom) using the same userland.
And with that kernel I could set the clock.
Using 2.6.37 or 2.6.38 afterwards, hwclock did function again, both read
an set are working.

So it looks like there is a catch22 in kernels >=2.6.37 (I haven't
tested .33-.36):

When the clock was never set, the alarm(-irq) doesn't work, so hwclock
doesn't work, so one can't set the clock.

Regards,

Alexander Holler


\
 
 \ /
  Last update: 2011-04-04 16:31    [W:0.047 / U:0.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site