[Gta04-owner] 3.0.8 kernel for Android/Replicant

NeilBrown neilb at suse.de
Thu Dec 13 08:13:58 CET 2012


On Thu, 06 Dec 2012 21:03:47 +0100 Paul Kocialkowski <paulk at paulk.fr> wrote:

> Le jeudi 06 décembre 2012 à 08:41 +1100, NeilBrown a écrit :
> > On Wed, 05 Dec 2012 22:18:43 +0100 Paul Kocialkowski <paulk at paulk.fr> wrote:
> > > The problem here seems to be that the IRQ isn't triggered everytime the
> > > pend is down on the touchscreen.
> > > 
> > > > Thanks again for your generous help!
> > > > My code is still up at:
> > > > http://git.paulk.fr/gitweb/?p=replicant/kernel-gta04.git;a=shortlog;h=refs/heads/replicant-4.0
> > 
> > I just tested the touch screen on my device  with your kernel and couldn't
> > fault it.
> 
> Well, I checked with the 3.2 kernel from Replicant 2.3, it works
> perfectly. Then I switched back to the 3.0.8 kernel and I do have
> dropped IRQ interrupts.
> 
> The latest HEAD of the kernel repo is
> f77ae2d5b19d6aadf1a504a75fc2d9bf42d781e8
> 
> I also tried backporting the 3.2 tsc2007 driver to 3.0.8, it didn't work
> any better (still touch events dropped). 
> 
> > I uncommented the printk  at the end of ts_get_pendown_state()  in
> > board-omap3gta04.c whenever I touch the screen I get a stream of
> 
> Mmh, you may have used an older revision than the current HEAD (I
> removed that particular printk, renamed ts_get_pendown_state and
> cleaned-up the tsc2007 platform code on the board file, in a desperate
> attempt to fix that issue). I have tried locally reverting these last
> few commits, it still doesn't work any better.
> 
> I didn't make it report the return value of the
> tsc2007_get_pendown_state, though the function isn't even called
> (because the IRQ isn't triggered), so it actually doesn't even read the
> GPIO value, nor does it report anything to userspace.
> 
> Android has a getevent utility that can be used to dump the events from
> the inputs: when the IRQ isn't triggered (but I am touching the screen
> after a pause), it doesn't report anything.
> 
> Sometimes, it looks like it works correctly for like 20 seconds or so,
> and after cycles of pauses/touches, it starts failing more and more
> often.
> 
> It's a bit strange that the issue doesn't seem to occur for you while
> it's very obvious here.

Different user-space I suspect.

I managed to reproduce it and I think I know roughly what is happening.
It is similar to the problem with losing characters on the serial port.

I think the CPU is dropping into a low  power state which ignores that
interrupt.  It is possible to arrange a wakeup when the interrupt happens,
but that isn't being done.
If you keep the CPU very busy (e.g. a tight loop) you should see the problem
go away (and the battery life drop).

If I'm right (and the tight-CPU-loop is a good test), then I don't really
have any hope of fixing it.

NeilBrown
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 828 bytes
Desc: not available
URL: <http://lists.goldelico.com/pipermail/gta04-owner/attachments/20121213/b00de0c0/attachment.bin>


More information about the Gta04-owner mailing list