1. 03 Apr, 2008 2 commits
    • Anssi Hannula's avatar
      Input: xpad - fix dpad handling of unknown devices · a0979923
      Anssi Hannula authored
      For devices not specifically listed in xpad.c, xpad->dpad_mapping
      is initially set to MAP_DPAD_UNKNOWN. In xpad_probe() it gets changed
      to either MAP_DPAD_TO_BUTTONS or MAP_DPAD_TO_AXES, depending on the
      module parameter dpad_to_buttons.
      
      However, MAP_DPAD_UNKNOWN is defined as -1, while the field is u8.
      This results in actual value of 255, causing the MAP_DPAD_UNKNOWN
      check in xpad_probe() to fail.
      Fix that by defining MAP_DPAD_UNKNOWN as 2 instead.
      
      Also, setting module parameter dpad_to_buttons to 1 should obviously
      map dpad to buttons, while the default behaviour (0) should be to map
      dpad to axes. However, dpad_to_buttons is directly assigned to
      xpad->dpad_mapping, and as MAP_DPAD_TO_BUTTONS is 0, the actual
      behaviour is reversed.
      Fix that by negating dpad_to_buttons in assignment.
      Signed-off-by: default avatarAnssi Hannula <anssi.hannula@gmail.com>
      Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
      a0979923
    • Anssi Hannula's avatar
      Input: xpad - match xbox 360 devices with interface info · 8a0f83ea
      Anssi Hannula authored
      Match Xbox 360 controllers using the interface info, i.e. interface
      class 255 (Vendor specific), subclass 93 and protocol 1, instead of
      specifying the device ids individually. As the class is vendor-specific,
      we have to still match against vendor id as well, though.
      Signed-off-by: default avatarAnssi Hannula <anssi.hannula@gmail.com>
      Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
      8a0f83ea
  2. 02 Apr, 2008 1 commit
  3. 01 Apr, 2008 2 commits
  4. 30 Mar, 2008 30 commits
  5. 29 Mar, 2008 5 commits