mirror of
https://github.com/torvalds/linux.git
synced 2026-06-08 06:25:52 +02:00
ANDROID: virtio: virtio_input: Set the amount of multitouch slots in virtio input
Virtio input was missing the the amount of multitouch
slots and kernel was filtering out ABS_MT_SLOT events
for a screen is touched in more than one place.
Bug: 143488374
Signed-off-by: Roman Kiryanov <rkir@google.com>
Change-Id: I617099435af311e6b0ee127b76eafe13834ea8f8
(cherry picked from commit af5cf146e4)
This commit is contained in:
parent
b4bf3761fd
commit
1a4bb30e3d
|
|
@ -2,6 +2,7 @@
|
|||
#include <linux/virtio.h>
|
||||
#include <linux/virtio_config.h>
|
||||
#include <linux/input.h>
|
||||
#include <linux/input/mt.h>
|
||||
|
||||
#include <uapi/linux/virtio_ids.h>
|
||||
#include <uapi/linux/virtio_input.h>
|
||||
|
|
@ -163,6 +164,12 @@ static void virtinput_cfg_abs(struct virtio_input *vi, int abs)
|
|||
virtio_cread(vi->vdev, struct virtio_input_config, u.abs.flat, &fl);
|
||||
input_set_abs_params(vi->idev, abs, mi, ma, fu, fl);
|
||||
input_abs_set_res(vi->idev, abs, re);
|
||||
if (abs == ABS_MT_TRACKING_ID)
|
||||
input_mt_init_slots(vi->idev,
|
||||
ma, /* input max finger */
|
||||
INPUT_MT_DIRECT
|
||||
| INPUT_MT_DROP_UNUSED
|
||||
| INPUT_MT_TRACK);
|
||||
}
|
||||
|
||||
static int virtinput_init_vqs(struct virtio_input *vi)
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user