Hi,

> Yes, if PS/2 keyboard emulation emulated the autorepeat rate/delay, then
> the code we have in QMP would just work.  However it would need to be
> done for all devices (ignoring repeated keydown events from the upper
> layers, and creating its own repeated event).  So it makes sense to have
> it in common code and have keyboard devices just tell common code the
> desired rate/delay.

Yep, that'll work too.

> BTW, how do we currently handle stuck keys across migration (where the
> key-up event never reaches the guest because the key was never pressed
> in the first place on the destination)?

We don't.

>> IIRC the (ps/2) kbd controller can be programmed with rate+delay.
> 
> Yes, but we ignore the command.  For the PS/2 keyboard, I think what we
> send now to the guest is based on the rate/delay that is emulated in
> software by the GUI layers (for Unix it should just be X11 for all of
> SDL/VNC/Spice).

Exactly.  Thats why keys getting stuck on migration isn't a big issue in
practice.

cheers,
  Gerd


Reply via email to