Skip to content
  • Javier Celaya's avatar
    1684907c
    Fix input-linux reading from device · 1684907c
    Javier Celaya authored
    
    
    The evdev devices in input-linux.c are read in blocks of one whole
    event. If there are not enough bytes available, they are discarded,
    instead of being kept for the next read operation. This results in
    lost events, of even non-working devices.
    
    This patch keeps track of the number of bytes to be read to fill up
    a whole event, and then handle it.
    
    Changes from v1 to v2:
    - Fix: Calculate offset on each iteration
    
    Changes from v2 to v3:
    - Fix coding style
    - Store offset instead of bytes to be read
    
    Signed-off-by: default avatarJavier Celaya <jcelaya@gmail.com>
    Message-id: 20170327182624.2914-1-jcelaya@gmail.com
    Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
    1684907c
    Fix input-linux reading from device
    Javier Celaya authored
    
    
    The evdev devices in input-linux.c are read in blocks of one whole
    event. If there are not enough bytes available, they are discarded,
    instead of being kept for the next read operation. This results in
    lost events, of even non-working devices.
    
    This patch keeps track of the number of bytes to be read to fill up
    a whole event, and then handle it.
    
    Changes from v1 to v2:
    - Fix: Calculate offset on each iteration
    
    Changes from v2 to v3:
    - Fix coding style
    - Store offset instead of bytes to be read
    
    Signed-off-by: default avatarJavier Celaya <jcelaya@gmail.com>
    Message-id: 20170327182624.2914-1-jcelaya@gmail.com
    Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
Loading