Skip to content
Snippets Groups Projects
Commit 0263b3a7 authored by Ladi Prosek's avatar Ladi Prosek Committed by Gerd Hoffmann
Browse files

virtio-input: fix emulated tablet axis ranges


The reported maximum was wrong. The X and Y coordinates are 0-based
so if size is 8000 maximum must be 7FFF.

Signed-off-by: default avatarLadi Prosek <lprosek@redhat.com>
Message-id: 1460128893-10244-1-git-send-email-lprosek@redhat.com
Signed-off-by: default avatarGerd Hoffmann <kraxel@redhat.com>
parent 2d738374
No related branches found
No related tags found
No related merge requests found
......@@ -484,12 +484,12 @@ static struct virtio_input_config virtio_tablet_config[] = {
.select = VIRTIO_INPUT_CFG_ABS_INFO,
.subsel = ABS_X,
.size = sizeof(virtio_input_absinfo),
.u.abs.max = const_le32(INPUT_EVENT_ABS_SIZE),
.u.abs.max = const_le32(INPUT_EVENT_ABS_SIZE - 1),
},{
.select = VIRTIO_INPUT_CFG_ABS_INFO,
.subsel = ABS_Y,
.size = sizeof(virtio_input_absinfo),
.u.abs.max = const_le32(INPUT_EVENT_ABS_SIZE),
.u.abs.max = const_le32(INPUT_EVENT_ABS_SIZE - 1),
},
{ /* end of list */ },
};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment