uinput broken for at least Mac mini

Bug #567512 reported by Reuben Thomas
34
This bug affects 6 people
Affects Status Importance Assigned to Milestone
lirc (Ubuntu)
Fix Released
Undecided
Unassigned
Lucid
Won't Fix
Undecided
Unassigned
Maverick
Won't Fix
Undecided
Unassigned

Bug Description

I have patched and tested the latest lirc packages from lucid. I have uploaded a bzr branch to Launchpad and requested a merge to lucid-proposed. The debdiff is also attached.

For the needs of the SRU:

- Impact of this bug: This bug renders the "--uinput" of lirc useless. This options allows remote controls to input commands like key strokes (as you would with a multimedia keyboard with "play", "next/previous", "volume up/down", etc buttons). This is obviously a very simple and attractive way to use a remote control with Ubuntu, and is recommended in many tutorials (including on help.ubuntu.com). Currently, in lucid, the buttons pressed on the remote have no effect (until the lircd daemon is stopped or restarted).

- Nominating for SRU, fulfills: (1) have an obviously safe patch (it only concerns the --uinput which is currently non-functional, and is tested by upstream and other distros) and (2) affect an application rather than critical infrastructure packages

- My proposed patch simply includes a patch from upstream (git commit d987ce9c68239f637dddb9de9f9668f6e8f9fc1d) to fix this problem. It is included in the 0.8.7~pre3-0ubuntu1 version in maverick, which works fine.

TEST CASE: A supported remote control and IR receiver are required.
Install the lirc package. Configure /etc/lirc/lircd.conf for your remote, if not already done during package installation (or include a preset from /usr/share/lirc/remotes/). Ensure your remote button presses are detected when running irw. Edit /etc/lirc/hardware.conf and set these keys:
REMOTE_MODULES="uinput"
REMOTE_LIRCD_ARGS="--uinput"
Restart lirc.
Start rhythmbox and enable the "lirc" module. Restart rhythmbox and start playing a song.
Press pause key on the remote and notice that rhythmbox doesn't take any notice.
Stop lirc, and see that rhythmbox then pauses the song.

I see no regression potential for this patch, as it only affects users running lirc with the --uinput option, which is currently non-functional with an up-to-date Ubuntu lucid.

---
Architecture: i386
DistroRelease: Ubuntu 10.04
Package: lirc 0.8.6-0ubuntu4.2
PackageArchitecture: i386
ProcEnviron:
 SHELL=/bin/bash
 PATH=(custom, user)
 LANG=en_GB.UTF-8
ProcVersionSignature: Ubuntu 2.6.32-25.44-generic 2.6.32.21+drm33.7
Tags: lucid
Uname: Linux 2.6.32-25-generic i686
UserGroups: adm admin audio cdrom dialout dip floppy fuse lpadmin netdev plugdev powerdev sambashare scanner src vboxusers video

Related branches

Revision history for this message
Reuben Thomas (rrt) wrote :
Revision history for this message
Reuben Thomas (rrt) wrote :

I just played around with the source package a bit. I tried removing some Ubuntu patches, to see if it helped, specifically, lirc_dev-2.6.33.patch and appleir_repeat_issue.patch. I removed first one and then the other, but installing the resultant packages did not fix the bug. Hence, it may be related to the kernel more than lirc. Note that the version of lirc shipped in Karmic is the same upstream, just with different patches, hence my hope that removing recently applied patches might help.

Revision history for this message
Reuben Thomas (rrt) wrote :

Further investigation: I reverted to the karmic kernel and lirc packages. No joy. I double-checked my configuration. No joy. I can't see how anything other than lirc and the kernel would be affecting this, but perhaps it is something else?

I'm very happy to take any further suggestions, as the lack of the remote is an annoyance.

Revision history for this message
Paul Reynolds (paulrreynolds) wrote :

I am having a similar problem with using uinput to redirect Serial data to keypresses. I am using the TypeKeys solution proposed by Loye Young, and it worked perfectly in Ubunty Jaunty.

When I upgraded to Karmic, uinput seems to have moved from /dev/input/uinput to dev/uinput. I have updated the program for this change, do you think this could be the problem?

Revision history for this message
Reuben Thomas (rrt) wrote :

The name of the device is not the problem, lirc checks several names, including the correct one for Lucid kernels.

Revision history for this message
Reuben Thomas (rrt) wrote :

I am using irexec as a workaround for this problem.

Revision history for this message
Panagiotis Skintzos (ph7) wrote :

Hi,

uinput via lirc is broken completely in Lucid currently. It happens with any remote I've tried.
The bug is in lirc and it is related to xf86-input-evdev. It is fixed upstream.
See http://bugs.gentoo.org/show_bug.cgi?id=299030
The patch attached there works fine with current lirc source from Lucid.
I applied it and now uinput works as before.

Revision history for this message
Jonathan Clarke (jooooooon) wrote :

Having just tested Maverick, I will note that this bug is fixed there (the version of lirc has been bumped to include the fix from the Gentoo bug report mentioned or something similar).

Is there any reason why this could not be patched and included as an update in Lucid? I'm willing to do the work, if someone points the way for me.

Changed in lirc (Ubuntu):
status: New → Fix Released
Revision history for this message
Mario Limonciello (superm1) wrote :

Jonathon:
If you want to go through the SRU process for that patch, it's listed here: https://wiki.ubuntu.com/StableReleaseUpdates. If you want to assemble the SRU package and propose it, that's fine.

Revision history for this message
Jonathan Clarke (jooooooon) wrote :

Thanks for the pointer Mario.

I have patched and tested the latest lirc packages from lucid. I have uploaded a bzr branch to Launchpad and requested a merge to lucid-proposed. The debdiff is also attached.

For the needs of the SRU:

- Impact of this bug: This bug renders the "--uinput" of lirc useless. This options allows remote controls to input commands like key strokes (as you would with a multimedia keyboard with "play", "next/previous", "volume up/down", etc buttons). This is obviously a very simple and attractive way to use a remote control with Ubuntu, and is recommended in many tutorials (including on help.ubuntu.com). Currently, in lucid, the buttons pressed on the remote have no effect (until the lircd daemon is stopped or restarted).

- Nominating for SRU, fulfills: (1) have an obviously safe patch (it only concerns the --uinput which is currently non-functional, and is tested by upstream and other distros) and (2) affect an application rather than critical infrastructure packages

- My proposed patch simply includes a patch from upstream (git commit d987ce9c68239f637dddb9de9f9668f6e8f9fc1d) to fix this problem. It is included in the 0.8.7~pre3-0ubuntu1 version in maverick, which works fine.

TEST CASE: A supported remote control and IR receiver are required.
Install the lirc package. Configure /etc/lirc/lircd.conf for your remote, if not already done during package installation (or include a preset from /usr/share/lirc/remotes/). Ensure your remote button presses are detected when running irw. Edit /etc/lirc/hardware.conf and set these keys:
REMOTE_MODULES="uinput"
REMOTE_LIRCD_ARGS="--uinput"
Restart lirc.
Start rhythmbox and enable the "lirc" module. Restart rhythmbox and start playing a song.
Press pause key on the remote and notice that rhythmbox doesn't take any notice.
Stop lirc, and see that rhythmbox then pauses the song.

I see no regression potential for this patch, as it only affects users running lirc with the --uinput option, which is currently non-functional with an up-to-date Ubuntu lucid.

Revision history for this message
Jonathan Clarke (jooooooon) wrote :
tags: added: patch patch-accepted-upstream
Revision history for this message
Reuben Thomas (rrt) wrote : Re: [Bug 567512] Re: uinput broken for at least Mac mini

Thanks very much for your work on this, maintainers, and in particular
for getting a fix together for Lucid. Much appreciated.

description: updated
Revision history for this message
Martin Pitt (pitti) wrote :

SRU ack, please upload.

Revision history for this message
Jonathan Clarke (jooooooon) wrote :

Thanks Martin. Now we just need a sponsor to upload this! :)

Revision history for this message
Mario Limonciello (superm1) wrote :

Jonathon:

Just uploaded it to the queue for you, thanks for getting it together.

Revision history for this message
Martin Pitt (pitti) wrote : Please test proposed package

Accepted lirc into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in lirc (Ubuntu Lucid):
status: New → Fix Committed
tags: added: verification-needed
Revision history for this message
Reuben Thomas (rrt) wrote : Dependencies.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
Reuben Thomas (rrt) wrote :

This version is an improvement, but unfortunately, it doesn't make uinput usable with a Mac remote.

When I install this version and configure it to use uinput, keycodes are generated. However, they are not fully correctly generated: Play/Pause works fine, but Volume up/down auto repeat, so that all I can do is either mute the sound or turn it up to max. Perhaps there's a problem with key up events? (I am guessing that for Play/Pause, key up is ignored, because it doesn't autorepeat.)

Please do let me know what other information I can supply (I have just run apport -u on this bug report, so that should have uploaded my current lirc config).

Revision history for this message
Reuben Thomas (rrt) wrote :

Clarification: in the above comment I meant that perhaps for Play/Pause, which does not autorepeat, key up events are ignored, or not needed.

Revision history for this message
Martin Pitt (pitti) wrote :

So it seems to be an improvement at least, and I think this can go to -updates.

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package lirc - 0.8.6-0ubuntu4.2

---------------
lirc (0.8.6-0ubuntu4.2) lucid-proposed; urgency=low

  * Fix bug where remote button presses are passed to uinput to be handled as
    standard key presses in X, but are ignored until lircd is stopped or
    restarted (LP: #567512).
    - debian/patches/uinput-send-syn.patch: Apply upstream patch
      d987ce9c68239f637dddb9de9f9668f6e8f9fc1d to restore passing of events to
      uinput.
 -- Jonathan Clarke <email address hidden> Wed, 08 Sep 2010 07:57:50 +0200

Changed in lirc (Ubuntu Lucid):
status: Fix Committed → Fix Released
Martin Pitt (pitti)
tags: added: pport-bug verification-done
removed: apport-bug verification-needed
tags: added: apport-bug
removed: pport-bug
Revision history for this message
Reuben Thomas (rrt) wrote :

As stated in the body of the report (and accepted by Martin Pitt, the maintainer who uploaded the fix), this bug is only partially fixed.

Changed in lirc (Ubuntu Maverick):
status: Fix Released → Confirmed
Changed in lirc (Ubuntu):
status: Fix Released → Confirmed
Changed in lirc (Ubuntu Lucid):
status: Fix Released → Confirmed
Revision history for this message
Rolf Leggewie (r0lf) wrote :

maverick has seen the end of its life and is no longer receiving any updates. Marking the maverick task for this ticket as "Won't Fix".

Changed in lirc (Ubuntu Maverick):
status: Confirmed → Won't Fix
Revision history for this message
Rolf Leggewie (r0lf) wrote :

lucid has seen the end of its life and is no longer receiving any updates. Marking the lucid task for this ticket as "Won't Fix".

Changed in lirc (Ubuntu Lucid):
status: Confirmed → Won't Fix
Revision history for this message
Alec Leamas (leamas-alec) wrote :

The new version 0.9.4c contains a new, separate deamomn lircd-uinput which is enhanced version of the --uinput option (which is deprecated). Could you please test against this new version?

Changed in lirc (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Reuben Thomas (rrt) wrote :

Thanks; I don't have that machine any more. If I operate a Mac mini with uinput remote in future I'll look into it!

Revision history for this message
Alec Leamas (leamas-alec) wrote :

If/when you do, please file a new bug. This one is too old and cluttered. Closing, as fixed in 0.9.4c

lirc (0.9.4b-0.1) experimental; urgency=medium

  * Non-maintainer upload.
  * First shot on major upstream updates.
    - Re-packaged from scratch based on new dh primitives.
    - Thanks for help on debian-mentors!
  * New upstream release 0.9.4
    - Release 0.9.1 .. 0.9.3 was never packaged.
    - Old 'lirc' service split into separate systemd services:
      lircd.service, lircmd.service and irexec.service.
    - Remote definitions moved out of lirc to new project
      lirc-remotes; affects large number of LP issues.
    - Builds also on FreeBSD 10.3.
    - Fixes "Not updated to last version" (Closes: #777199),
      LP: #1443590.
    - Fixes "Default device for mode2 is /dev/lirc" (Closes: #702140).
    - Fixes "/var/run/lirc contents disappear..." (Closes: #676343).
    - Fixes "lircrcd segfaults" (Closes: #780062).
    - Fixes "'/etc/init.d/lirc restart' is broken" (Closes: #782091).
    - Fixes "Prompting due to modified conffiles..." (Closes: #655969).
    - Fixes "LIRC installs bad udev rule" (Closes: #804397),
      users depending on this rule will need to explicitly start lircd.
    - Fixes "lirc init script can create circular symlinks", LP: #698007.
    - Fixes "Update Uploaders List (Closes: #762554).
    - Fixes "Please switch to libftdi1" (Closes: #810370).
    - Fixes LP: #153457 "iguanaIR support not functional".
    - Fixes LP: #460027 "using lirc init script restart function fails
      sometimes".
    - Fixes LP: #499588 "lirc udev rule causes unreliable startup".
    - Fixes LP: #567519 "lircd(8) mentions non-existent
      /dev/input/uinput".
    - Fixes LP: #1029604 "mce remote doesn't work due to out of date
      lircd.conf.devinput".
    - Fixes LP: #1312287 "lircd start problem".
  * The built-in irman support is moved to the lirc-drv-irman package.
  * Revised package structure: keep old liblircclient0 (renamed to
    liblirc-client0). Adding new packages liblirc0, liblirc-dev and
    lirc-doc. Former liblircclient-dev merged into new liblirc-dev.
  * Don't overwrite existing lircd.conf file.
  * Ship sysV scripts from the svn tree [Stefan Lippers-Hollmann]
  * Add handling of obsolete 0.9.0 udev rule restarting lircd
  * Old lircd output socket link /dev/lirc dropped. Use
    /var/run/lirc/lircd.
  * Updated copyright
  * Update compiler flags: -Wl,as-needed + hardening
    [Stefan Lippers-Hollmann]
  * Avoid negative architecture deps like [!hurd] (Closes: #634807)
    [Stefan Lippers-Hollmann]
  * Add patch 0007-tools-remove-configs-symlink.patch + explicit link
    to walk around #801719 (dh_python3 shortcomings).
  * Last parts of libirman dependencies removed.
  * Changing Vcs-* headers to point to upstream packaging branch.
  * Fixes existing large number of upgrade bugs.
  * Enhance hardening flags.
  * Add a lintian pbuilder test, this requires --hookdir and B92-test-pkg
    therein.
  * Tested (build-wise) on stretch and sid.

 -- Alec Leamas <email address hidden> Thu, 26 May 2016 11:14:25 +0100

Changed in lirc (Ubuntu):
status: Incomplete → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.