From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dmitry Torokhov Subject: Re: [PATCH update] firedtv: fix remote control with newer Xorg evdev Date: Mon, 17 Jan 2011 09:00:15 -0800 Message-ID: <20110117170015.GA15404@core.coreip.homeip.net> References: <20110116093921.6275ac89@stein> <20110117081703.GA22802@core.coreip.homeip.net> <20110117141758.56af41f5@stein> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mail-pv0-f174.google.com ([74.125.83.174]:44583 "EHLO mail-pv0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751955Ab1AQRA0 (ORCPT ); Mon, 17 Jan 2011 12:00:26 -0500 Content-Disposition: inline In-Reply-To: <20110117141758.56af41f5@stein> Sender: linux-input-owner@vger.kernel.org List-Id: linux-input@vger.kernel.org To: Stefan Richter Cc: linux-media@vger.kernel.org, linux-input@vger.kernel.org, linux1394-devel@lists.sourceforge.net On Mon, Jan 17, 2011 at 02:17:58PM +0100, Stefan Richter wrote: > After a recent update of xf86-input-evdev and xorg-server, I noticed > that X11 applications did not receive keypresses from the FireDTV > infrared remote control anymore. Instead, the Xorg log featured lots of > > "FireDTV remote control: dropping event due to full queue!" > > exclamations. The Linux console did not have an issue with the > FireDTV's RC though. > > The fix is to insert EV_SYN events after the key-down/-up events. > Dimitry notes that EV_SYN is also necessary between down and up, > otherwise userspace could combine their state. > > Signed-off-by: Stefan Richter Acked-by: Dmitry Torokhov > --- > drivers/media/dvb/firewire/firedtv-rc.c | 9 ++++++--- > 1 file changed, 6 insertions(+), 3 deletions(-) > > Index: b/drivers/media/dvb/firewire/firedtv-rc.c > =================================================================== > --- a/drivers/media/dvb/firewire/firedtv-rc.c > +++ b/drivers/media/dvb/firewire/firedtv-rc.c > @@ -172,7 +172,8 @@ void fdtv_unregister_rc(struct firedtv * > > void fdtv_handle_rc(struct firedtv *fdtv, unsigned int code) > { > - u16 *keycode = fdtv->remote_ctrl_dev->keycode; > + struct input_dev *idev = fdtv->remote_ctrl_dev; > + u16 *keycode = idev->keycode; > > if (code >= 0x0300 && code <= 0x031f) > code = keycode[code - 0x0300]; > @@ -188,6 +189,8 @@ void fdtv_handle_rc(struct firedtv *fdtv > return; > } > > - input_report_key(fdtv->remote_ctrl_dev, code, 1); > - input_report_key(fdtv->remote_ctrl_dev, code, 0); > + input_report_key(idev, code, 1); > + input_sync(idev); > + input_report_key(idev, code, 0); > + input_sync(idev); > } > > > -- > Stefan Richter > -=====-==-== ---= =---= > http://arcgraph.de/sr/ -- Dmitry