qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] hw/vmmouse.c: Disable vmmouse after reboot
@ 2012-01-25 20:04 Gerhard Wiesinger
  2012-01-26  8:26 ` Andreas Färber
  2012-02-03 17:21 ` Anthony Liguori
  0 siblings, 2 replies; 7+ messages in thread
From: Gerhard Wiesinger @ 2012-01-25 20:04 UTC (permalink / raw)
  To: qemu-devel

Bugfix after reboot when vmmouse was enabled and another OS which uses e.g. PS/2
mouse.

Details:
When a guest activated the vmmouse followed by a reboot the vmmouse was still
enabled and the PS/2 mouse was therefore unsusable. When another guest is then
booted without vmmouse support (e.g. PS/2 mouse) the mouse is not working.

Reason is that VMMouse has priority and disables all other mouse entities
and therefore must be disabled on reset.

Testscenario:
1.) Boot e.g. OS with VMMouse support (e.g. Windows with VMMouse tools)
2.) reboot
3.) Boot e.g. OS without VMMouse support (e.g. DOS) => PS/2 mouse doesn't work
     any more. Fixes that issue.

Testscenario 2 by Jan Kiszka <jan.kiszka@siemens.com>:
Confirm that this patch fixes a real issue. Setup: qemu.git,
opensuse 11.4 guest, SDL graphic, system_reset while guest is using the
vmmouse. Without the patch, the vmmouse become unusable after the
reboot. Also, the mouse stays in absolute mode even before X starts again.

Fixed by:
Disabling the vmmouse in its reset handler.

Signed-off-by: Gerhard Wiesinger <lists@wiesinger.com>
---
  hw/vmmouse.c |    2 ++
  1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/hw/vmmouse.c b/hw/vmmouse.c
index 1113f33..f9f5b53 100644
--- a/hw/vmmouse.c
+++ b/hw/vmmouse.c
@@ -254,6 +254,8 @@ static void vmmouse_reset(DeviceState *d)

      s->status = 0xffff;
      s->queue_size = VMMOUSE_QUEUE_SIZE;
+
+    vmmouse_disable(s);
  }

  static int vmmouse_initfn(ISADevice *dev)
-- 
1.7.7.6

^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2012-08-22 17:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-25 20:04 [Qemu-devel] [PATCH] hw/vmmouse.c: Disable vmmouse after reboot Gerhard Wiesinger
2012-01-26  8:26 ` Andreas Färber
2012-01-27  6:53   ` Gerhard Wiesinger
2012-02-03 17:21 ` Anthony Liguori
2012-02-03 17:57   ` Gerhard Wiesinger
2012-08-22 17:01     ` Andreas Färber
2012-08-22 16:54   ` Andreas Färber

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).