Hi! Am Freitag, den 26.01.2007, 03:51 +0100 schrieb Vincent Penne: > hermann pitton a écrit : > > Hi Vincent, > > > > after having some time to look at it, it turns out my memory was > > corrupted. > > > > You are definitely right. > > A single return < 28000 will lock up the whole decoding needlessly. > > > > We should keep it, since I can produce conditions returning the other > > dprintk(s), but not this one without changing the code to force it. > > > > Please provide a patch for your finding and sign-off. > > Seems to move it below > > > > ir->active = 0; > > > > is sufficient. > > > > > > Here the links how the code came in. > > > > Marks patch submission and followups with Nickolay. > > http://marc.theaimsgroup.com/?l=linux-video&m=112841901208867&w=2 > > > > Mark must have missed Nickolay's modifications. Last I find is here from > > him then with comments. > > http://marc.theaimsgroup.com/?l=linux-video&m=113735813926708&w=2 > > > > Thanks, > > Hermann > > > > > > Here is the patch as attachement. By the way, all my problems with the > remote are now fixed : I'm now using the stock kernel 2.6.19.2 (so now > ACPI works fine with my motherboard and I have usb working without the > "irqpoll" option). After two days testing with the machine doing various > things (compiling, playing games, crunching prime numbers, recording and > watching TV, receiving emails , etc ...) and a lot of use of the remote, > it's still working all fine. > > This patch is very simple, it moves the resetting of ir->active in the > function ir_rc5_timer_end before > the test gap < 28000 so that the remote continues working even after > this rare case arises. > > Signed-off-by: Vincent Penne <ziggy@xxxxxxxxxxx> Signed-off-by: Hermann Pitton <hermann-pitton@xxxxxxxx> Vincent, thanks a lot for doing stress tests on your critical hardware and for discovering this bug. Please, Mauro, Hartmut or Michael, can one of you pick it up ? We don't want to see it on 2.6.21 again. Thanks, Hermann > Cheers, > > Vincent Penne > > einfaches Textdokument-Anlage (my-lockup-fix.patch) > diff -r cf2c23e0f950 linux/drivers/media/common/ir-functions.c > --- a/linux/drivers/media/common/ir-functions.c Thu Jan 25 06:00:01 2007 -0200 > +++ b/linux/drivers/media/common/ir-functions.c Fri Jan 26 03:37:34 2007 +0100 > @@ -318,13 +318,15 @@ void ir_rc5_timer_end(unsigned long data > tv.tv_usec - ir->base_time.tv_usec; > } > > - /* Allow some timmer jitter (RC5 is ~24ms anyway so this is ok) */ > + /* signal we're ready to start a new code */ > + ir->active = 0; > + > + /* Allow some timer jitter (RC5 is ~24ms anyway so this is ok) */ > if (gap < 28000) { > dprintk(1, "ir-common: spurious timer_end\n"); > return; > } > > - ir->active = 0; > if (ir->last_bit < 20) { > /* ignore spurious codes (caused by light/other remotes) */ > dprintk(1, "ir-common: short code: %x\n", ir->code); > --
diff -r 8a62d21302f5 linux/drivers/media/common/ir-functions.c --- a/linux/drivers/media/common/ir-functions.c Fri Jan 26 11:30:05 2007 +++ b/linux/drivers/media/common/ir-functions.c Fri Jan 26 21:15:15 2007 @@ -318,13 +318,15 @@ tv.tv_usec - ir->base_time.tv_usec; } - /* Allow some timmer jitter (RC5 is ~24ms anyway so this is ok) */ + /* signal we're ready to start a new code */ + ir->active = 0; + + /* Allow some timer jitter (RC5 is ~24ms anyway so this is ok) */ if (gap < 28000) { dprintk(1, "ir-common: spurious timer_end\n"); return; } - ir->active = 0; if (ir->last_bit < 20) { /* ignore spurious codes (caused by light/other remotes) */ dprintk(1, "ir-common: short code: %x\n", ir->code);
_______________________________________________ linux-dvb mailing list linux-dvb@xxxxxxxxxxx http://www.linuxtv.org/cgi-bin/mailman/listinfo/linux-dvb