Re: [Qemu-devel] [PATCH v2] ps2: set ps/2 output buffer size as the same as kernel

2014-04-24 Thread Gonglei (Arei)
Hi, Gerd. > > > if (!(s->mouse_status & MOUSE_STATUS_REMOTE) && > > -(s->common.queue.count < (PS2_QUEUE_SIZE - 16))) { > > +(s->common.queue.count < PS2_QUEUE_SIZE - 4)) { > > for(;;) { > > Almost there. > > The check for enougth space in the queue should be for ev

[Qemu-devel] [PATCH v2] ps2: set ps/2 output buffer size as the same as kernel

2014-04-24 Thread arei.gonglei
From: Gonglei According to the PS/2 Mouse/Keyboard Protocol, the keyboard outupt buffer size is 16 bytes. And the PS2_QUEUE_SIZE 256 was introduced in Qemu from the very beginning. When I started a redhat5.6 32bit guest, meanwhile tapped the keyboard as quickly as possible, the screen would sh

Re: [Qemu-devel] [PATCH v2] ps2: set ps/2 output buffer size as the same as kernel

2014-04-24 Thread Gerd Hoffmann
Hi, > if (!(s->mouse_status & MOUSE_STATUS_REMOTE) && > -(s->common.queue.count < (PS2_QUEUE_SIZE - 16))) { > +(s->common.queue.count < PS2_QUEUE_SIZE - 4)) { > for(;;) { Almost there. The check for enougth space in the queue should be for every ps2_mouse_send_pac