From: Owen Smith Date: Fri, 3 Nov 2017 11:56:31 +0000 (+0000) Subject: xenfb: activate input handlers for raw pointer devices X-Git-Tag: v2.12.1~379^2~1 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=d12c5b7ddf2cee57f3e72fe6f450203a9ab455ed;p=mirror_qemu.git xenfb: activate input handlers for raw pointer devices If the frontend requests raw pointers, the input handlers must be activated to have the input events delivered to the xenfb backend. Without activation, the input events are delivered to handlers registered earlier, which would be the emulated USB tablet or emulated PS/2 mouse. HVM xen_kbdfront can incorrectly scale absolute coordinates when the display resolution is not 800x600. Signed-off-by: Owen Smith Reviewed-by: Gerd Hoffmann Reviewed-by: Stefano Stabellini Signed-off-by: Stefano Stabellini --- diff --git a/hw/display/xenfb.c b/hw/display/xenfb.c index 776a2ce559..d4fc0fa5f2 100644 --- a/hw/display/xenfb.c +++ b/hw/display/xenfb.c @@ -387,6 +387,11 @@ static void input_connected(struct XenDevice *xendev) in->qkbd = qemu_input_handler_register((DeviceState *)in, &xenfb_keyboard); in->qmou = qemu_input_handler_register((DeviceState *)in, in->abs_pointer_wanted ? &xenfb_abs_mouse : &xenfb_rel_mouse); + + if (in->raw_pointer_wanted) { + qemu_input_handler_activate(in->qkbd); + qemu_input_handler_activate(in->qmou); + } } static void input_disconnect(struct XenDevice *xendev)