diff mbox

[PULL,01/15] ps2kbd: default to scancode_set 2, as with KBD_CMD_RESET

Message ID 1460047845-14488-2-git-send-email-pbonzini@redhat.com (mailing list archive)
State New, archived
Headers show

Commit Message

Paolo Bonzini April 7, 2016, 4:50 p.m. UTC
From: Hervé Poussineau <hpoussin@reactos.org>

This line has been added in commit ef74679a810fe6858f625b9d52b68cc3fc61eb3d with
other initializations. However, scancode set 0 doesn't exist (only 1, 2, 3).
This works well as long as operating system is resetting keyboard, or overwriting
the current scancode set with the one it wants.

This fixes IBM 40p firmware, which doesn't bother sending KBD_CMD_RESET or KBD_CMD_SCANCODE.

Signed-off-by: Hervé Poussineau <hpoussin@reactos.org>
Message-Id: <1458714100-28885-1-git-send-email-hpoussin@reactos.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 hw/input/ps2.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Peter Maydell April 7, 2016, 6:04 p.m. UTC | #1
On 7 April 2016 at 17:50, Paolo Bonzini <pbonzini@redhat.com> wrote:
> From: Hervé Poussineau <hpoussin@reactos.org>
>
> This line has been added in commit ef74679a810fe6858f625b9d52b68cc3fc61eb3d with
> other initializations. However, scancode set 0 doesn't exist (only 1, 2, 3).
> This works well as long as operating system is resetting keyboard, or overwriting
> the current scancode set with the one it wants.
>
> This fixes IBM 40p firmware, which doesn't bother sending KBD_CMD_RESET or KBD_CMD_SCANCODE.
>
> Signed-off-by: Hervé Poussineau <hpoussin@reactos.org>
> Message-Id: <1458714100-28885-1-git-send-email-hpoussin@reactos.org>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>

Something has gone wrong with the accented character in
Hervé's signed-off-by line (you can see it is ok in the From line).

Would you mind fixing it and resending the pull request?

thanks
-- PMM
diff mbox

Patch

diff --git a/hw/input/ps2.c b/hw/input/ps2.c
index 58892d5..a8aa36f 100644
--- a/hw/input/ps2.c
+++ b/hw/input/ps2.c
@@ -628,7 +628,7 @@  static void ps2_kbd_reset(void *opaque)
     ps2_common_reset(&s->common);
     s->scan_enabled = 0;
     s->translate = 0;
-    s->scancode_set = 0;
+    s->scancode_set = 2;
 }
 
 static void ps2_mouse_reset(void *opaque)