Linux [xbmcbuntu] inputlirc and udev remote race condition
#1
I'm using XBMCBuntu (Ubuntu 12.10 version) with Gotham 13.2. Short version is that I am using inputlirc at I had too many issues with lircd however I find that intermittently it fails to start and segfaults instead:

Code:
Aug 26 08:58:20 NUC kernel: [    4.251758] lirc_dev: IR Remote Control driver registered, major 250
Aug 26 08:58:20 NUC kernel: [    4.252400] rc rc0: lirc_dev: driver ir-lirc-codec (mceusb) registered at minor = 0
Aug 26 08:58:20 NUC kernel: [    4.252404] IR LIRC bridge handler initialized
Aug 26 08:58:21 NUC inputlircd: Could not open /dev/input/myremote: No such file or directory
Aug 26 08:58:21 NUC inputlircd: Started
Aug 26 08:58:21 NUC kernel: [    4.408317] inputlircd[1098]: segfault at dff6f9b8 ip 08049739 sp bff6f950 error 7 in inputlircd[8048000+4000]

Presumably the segfault is because the device isn't registered yet and I have a race condition, if I quit xbmc, start inputlirc and restart it then all is well and by the time the system is booted the device is always present.

I'm registering the device with udev using this:
Code:
paul@NUC:~$ cat /etc/udev/rules.d/10-persistent-ir.rules
KERNEL=="event*",ATTRS{name}=="Media Center Ed. eHome Infrared Remote Transceiver (1934:5168)",SYMLINK="input/myremote"

Any suggestions as to how I can add a dependency or delay to ensure the device is registered before inplutlirc starts please?
Reply
#2
having your xbmc(or lightdm) upstart script
Code:
Start on (....
              and stopped udevtrigger)

might do the trick
Reply
#3
Thanks for the suggestion. Just so I understand though, that looks like it will make the windowserver and hence xbmc wait until the scan of devices is done, but I'm thinking that inputlirc has probably tried to start a while before that and maybe I need to be looking at /etc/init.d/inputlirc instead?
Reply

Logout Mark Read Team Forum Stats Members Help
[xbmcbuntu] inputlirc and udev remote race condition0