Comment 3 for bug 1003053

Revision history for this message
monochromec (monochromec) wrote :

Seems to be related to mouse detection in the function scan_for_devs ().

The if branch starting with

" if (test_bit(EV_REL, bit)) {
    int i;
    /* our own virtual mouse (on rescans)*/
    if (id[ID_PRODUCT] == 0x1E && id[ID_VENDOR] == 0x1F) {
     close(fd);
     continue;"

is never entered on my 8.1 (discovered this after suitable instrumentation of the code in the function). As a result, no mouse is registered as a virtual device and event_parse doesn't have a chance to detect clicks in connection with pressing of modifier keys as it's intended with this tool.

Don't know enough about uinput / event handling in connection with Apple-specific hardware to investigate further. If it helps, here an excerpt of the lsusb command:

Bus 001 Device 005: ID 05ac:0253 Apple, Inc. Internal Keyboard/Trackpad (ISO)
Device Descriptor:
  bLength 18
  bDescriptorType 1
  bcdUSB 2.00
  bDeviceClass 0 (Defined at Interface level)
  bDeviceSubClass 0
  bDeviceProtocol 0
  bMaxPacketSize0 8
  idVendor 0x05ac Apple, Inc.
  idProduct 0x0253 Internal Keyboard/Trackpad (ISO)
  bcdDevice 1.18
  iManufacturer 1 Apple Inc.
  iProduct 2 Apple Internal Keyboard / Trackpad
  iSerial 0
  bNumConfigurations 1
  Configuration Descriptor:
    bLength 9
    bDescriptorType 2
    wTotalLength 84
    bNumInterfaces 3
    bConfigurationValue 1
    iConfiguration 0
    bmAttributes 0xa0
      (Bus Powered)
      Remote Wakeup
    MaxPower 40mA
    Interface Descriptor:
      bLength 9
      bDescriptorType 4
      bInterfaceNumber 0
      bAlternateSetting 0
      bNumEndpoints 1
      bInterfaceClass 3 Human Interface Device
      bInterfaceSubClass 1 Boot Interface Subclass
      bInterfaceProtocol 1 Keyboard
      iInterface 3 Apple Internal Keyboard
        HID Device Descriptor:
          bLength 9
          bDescriptorType 33
          bcdHID 1.11
          bCountryCode 13 International (ISO)
          bNumDescriptors 1
          bDescriptorType 34 Report
          wDescriptorLength 156
         Report Descriptors:
           ** UNAVAILABLE **
      Endpoint Descriptor:
        bLength 7
        bDescriptorType 5
        bEndpointAddress 0x83 EP 3 IN
        bmAttributes 3
          Transfer Type Interrupt
          Synch Type None
          Usage Type Data
        wMaxPacketSize 0x000a 1x 10 bytes
        bInterval 8
    Interface Descriptor:
      bLength 9
      bDescriptorType 4
      bInterfaceNumber 1
      bAlternateSetting 0
      bNumEndpoints 1
      bInterfaceClass 3 Human Interface Device
      bInterfaceSubClass 0 No Subclass
      bInterfaceProtocol 0 None
      iInterface 4 Touchpad
        HID Device Descriptor:
          bLength 9
          bDescriptorType 33
          bcdHID 1.11
          bCountryCode 0 Not supported
          bNumDescriptors 1
          bDescriptorType 34 Report
          wDescriptorLength 27
         Report Descriptors:
           ** UNAVAILABLE **
      Endpoint Descriptor:
        bLength 7
        bDescriptorType 5
        bEndpointAddress 0x81 EP 1 IN
        bmAttributes 3
          Transfer Type Interrupt
          Synch Type None
          Usage Type Data
        wMaxPacketSize 0x0040 1x 64 bytes
        bInterval 2
    Interface Descriptor:
      bLength 9
      bDescriptorType 4
      bInterfaceNumber 2
      bAlternateSetting 0
      bNumEndpoints 1
      bInterfaceClass 3 Human Interface Device
      bInterfaceSubClass 1 Boot Interface Subclass
      bInterfaceProtocol 2 Mouse
      iInterface 4 Touchpad
        HID Device Descriptor:
          bLength 9
          bDescriptorType 33
          bcdHID 1.11
          bCountryCode 0 Not supported
          bNumDescriptors 1
          bDescriptorType 34 Report
          wDescriptorLength 52
         Report Descriptors:
           ** UNAVAILABLE **
      Endpoint Descriptor:
        bLength 7
        bDescriptorType 5
        bEndpointAddress 0x84 EP 4 IN
        bmAttributes 3
          Transfer Type Interrupt
          Synch Type None
          Usage Type Data
        wMaxPacketSize 0x0008 1x 8 bytes
        bInterval 8
Device Status: 0x0000
  (Bus Powered)