1. 23 Dec, 2010 1 commit
  2. 16 Dec, 2010 16 commits
  3. 08 Dec, 2010 2 commits
  4. 01 Dec, 2010 3 commits
  5. 22 Nov, 2010 5 commits
  6. 20 Nov, 2010 1 commit
    • Jesper Juhl's avatar
      Input: serio HIL MLC - don't deref null, don't leak and return proper error · 39de5210
      Jesper Juhl authored
      While reviewing various users of kernel memory allocation functions I came
      across drivers/input/serio/hil_mlc.c::hil_mlc_register() and noticed that:
      
       - it calls kzalloc() but fails to check for a NULL return before use.
       - it makes several allocations and if one fails it doesn't free the
         previous ones.
       - It doesn't return -ENOMEM in the failed memory allocation case (it just
         crashes).
      
      This patch corrects all of the above and also reworks the only caller of
      this function that I could find
      (drivers/input/serio/hp_sdc_mlc.c::hp_sdc_mlc_out()) so that it now checks
      the return value of hil_mlc_register() and properly propagates it on
      failure and I also restructured the code to remove some labels and goto's
      to make it, IMHO nicer to read.
      Signed-off-by: default avatarJesper Juhl <jj@chaosbits.net>
      Tested-by: default avatarHelge Deller <deller@gmx.de>
      Acked-by: default avatarHelge Deller <deller@gmx.de>
      Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
      39de5210
  7. 19 Nov, 2010 1 commit
  8. 18 Nov, 2010 5 commits
  9. 15 Nov, 2010 3 commits
  10. 12 Nov, 2010 3 commits
    • Dmitry Torokhov's avatar
      Input: mac mouse emulation - add locking · 87abb6bb
      Dmitry Torokhov authored
      We need to add appropriate locking when toggling mac mouse emulation
      on and off to ensure that input device and handler are in consistent
      state.
      Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
      87abb6bb
    • Daniel Drake's avatar
      Input: hgpk - extend jumpiness detection · a309cdc7
      Daniel Drake authored
      In addition to forcing recalibrations upon detection of cursor jumps (and
      performing them quicker than before), detect and discard errant 'jump'
      packets caused by a firmware bug, which are then repeated with each one
      being approximately half the delta of the one previously (as if it is
      averaging out)
      
      Based on original work by Paul Fox.
      Signed-off-by: default avatarDaniel Drake <dsd@laptop.org>
      Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
      a309cdc7
    • Daniel Drake's avatar
      Input: hgpk - rework spew detection · c0dc8342
      Daniel Drake authored
      The old implementation of spew detection simply tracked the overall
      position delta of the cursor over every 100 packets. We found that
      this causes occasional false positives in spew detection, and also
      that the conditions of the spewy packets are perhaps more fixed than
      we once thought.
      
      Rework the spew detection to look for packets of specific small
      delta, and only recalibrating if the overall movement delta stays
      within expected bounds.
      
      Also discard duplicate packets in the advanced mode, which appear
      to be very common. If we don't, the spew detection kicks in far
      too early. If we get a large spew of duplicates, request a
      recalibration straight up.
      
      Based on earlier work by Paul Fox.
      Signed-off-by: default avatarDaniel Drake <dsd@laptop.org>
      Signed-off-by: default avatarDmitry Torokhov <dtor@mail.ru>
      c0dc8342