udev regras para adicionar joystick para arm linux?

1

Eu estou tentando adicionar um ambiente ID_INPUT_JOYSTICK = 1 ao udev quando um joystick é adicionado ao meu sistema. Isso não é necessário para desktop Ubuntu porque a propriedade já está lá, mas em uma versão linux estou usando ele não mostra. O sistema de destino é uma versão do braço do linux. Então, a execução das informações do udevadm mostra:

looking at device '/devices/platform/xhci-hcd.1/usb3/3-1/3-1:1.0/input/input6/event6':
    KERNEL=="event6"
    SUBSYSTEM=="input"
    DRIVER==""

  looking at parent device '/devices/platform/xhci-hcd.1/usb3/3-1/3-1:1.0/input/input6':
    KERNELS=="input6"
    SUBSYSTEMS=="input"
    DRIVERS==""
    ATTRS{name}=="Logitech Logitech RumblePad 2 USB"
    ATTRS{phys}=="usb-xhci-hcd.1-1/input0"
    ATTRS{uniq}==""
    ATTRS{properties}=="0"

  looking at parent device '/devices/platform/xhci-hcd.1/usb3/3-1/3-1:1.0':
    KERNELS=="3-1:1.0"
    SUBSYSTEMS=="usb"
    DRIVERS=="usbhid"
    ATTRS{bInterfaceClass}=="03"
    ATTRS{bInterfaceSubClass}=="00"
    ATTRS{bInterfaceProtocol}=="00"
    ATTRS{bNumEndpoints}=="02"
    ATTRS{supports_autosuspend}=="1"
    ATTRS{bAlternateSetting}==" 0"
    ATTRS{bInterfaceNumber}=="00"

  looking at parent device '/devices/platform/xhci-hcd.1/usb3/3-1':
    KERNELS=="3-1"
    SUBSYSTEMS=="usb"
    DRIVERS=="usb"
    ATTRS{bDeviceSubClass}=="00"
    ATTRS{bDeviceProtocol}=="00"
    ATTRS{devpath}=="1"
    ATTRS{idVendor}=="046d"
    ATTRS{speed}=="1.5"
    ATTRS{bNumInterfaces}==" 1"
    ATTRS{bConfigurationValue}=="1"
    ATTRS{bMaxPacketSize0}=="8"
    ATTRS{busnum}=="3"
    ATTRS{devnum}=="2"
    ATTRS{configuration}==""
    ATTRS{bMaxPower}=="500mA"
    ATTRS{authorized}=="1"
    ATTRS{bmAttributes}=="80"
    ATTRS{bNumConfigurations}=="1"
    ATTRS{maxchild}=="0"
    ATTRS{bcdDevice}=="0100"
    ATTRS{avoid_reset_quirk}=="0"
    ATTRS{quirks}=="0x0"
    ATTRS{version}==" 1.10"
    ATTRS{urbnum}=="16"
    ATTRS{ltm_capable}=="no"
    ATTRS{manufacturer}=="Logitech"
    ATTRS{removable}=="unknown"
    ATTRS{idProduct}=="c218"
    ATTRS{bDeviceClass}=="00"

Mas eu quero que eu veja um ENV {ID_INPUT_JOYSTICK}="1" adicionado ao final, algo como:

looking at device '/devices/platform/xhci-hcd.1/usb3/3-1/3-1:1.0/input/input6/event6':
    KERNEL=="event6"
    SUBSYSTEM=="input"
    DRIVER==""
  looking at parent device '/devices/platform/xhci-hcd.1/usb3/3-1/3-1:1.0/input/input6':
    KERNELS=="input6"
    SUBSYSTEMS=="input"
    DRIVERS==""
    ATTRS{name}=="Logitech Logitech RumblePad 2 USB"
    ATTRS{phys}=="usb-xhci-hcd.1-1/input0"
    ATTRS{uniq}==""
    ATTRS{properties}=="0"
    ENV{ID_INPUT_JOYSTICK}="1"
    ..

As regras que adicionei são estas: /etc/udev/rules.d/91-joystick-rules

SUBSYSTEMS=="input", ATTRS{name}=="Logitech Logitech RumblePad 2 USB", MODE="0666", ENV{ID_INPUT_JOYSTICK}="1"

Além disso, o /lib/udev/rules.d/ difere do desktop ubuntu:

-rw-r--r--    1 1003     1003         11741 May 27  2014 95-keymap.rules
-rw-r--r--    1 1003     1003           131 May 17  2014 90-alsa-restore.rules
-rw-r--r--    1 1003     1003          5570 May 17  2014 90-pulseaudio.rules
-rw-r--r--    1 1003     1003          1356 May 17  2014 97-bluetooth-hid2hci.rules
-rw-r--r--    1 1003     1003          2732 May 17  2014 42-usb-hid-pm.rules
-rw-r--r--    1 1003     1003          3652 May 17  2014 50-udev-default.rules
-rw-r--r--    1 1003     1003           646 May 17  2014 60-cdrom_id.rules
-rw-r--r--    1 1003     1003           616 May 17  2014 60-persistent-alsa.rules
-rw-r--r--    1 1003     1003          2400 May 17  2014 60-persistent-input.rules
-rw-r--r--    1 1003     1003           947 May 17  2014 60-persistent-serial.rules
-rw-r--r--    1 1003     1003          1420 May 17  2014 60-persistent-storage-tape.rules
-rw-r--r--    1 1003     1003          5622 May 17  2014 60-persistent-storage.rules
-rw-r--r--    1 1003     1003           769 May 17  2014 60-persistent-v4l.rules
-rw-r--r--    1 1003     1003           166 May 17  2014 61-accelerometer.rules
-rw-r--r--    1 1003     1003           570 May 17  2014 75-net-description.rules
-rw-r--r--    1 1003     1003           255 May 17  2014 75-probe_mtd.rules
-rw-r--r--    1 1003     1003           570 May 17  2014 75-tty-description.rules
-rw-r--r--    1 1003     1003          4174 May 17  2014 78-sound-card.rules
-rw-r--r--    1 1003     1003           565 May 17  2014 80-drivers.rules
-rw-r--r--    1 1003     1003          3328 May 17  2014 95-keyboard-force-release.rules
-rw-r--r--    1 1003     1003           155 May 17  2014 95-udev-late.rules

Eu tentei reinicializar meu sistema e brincar com as regras específicas, mas não consigo entender por que meu ambiente adicionado não está sendo exibido. Qualquer ajuda é apreciada.

    
por Jay Chung 28.05.2014 / 03:21

0 respostas

Tags