[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 13/14] pckbd: clear outport_present in outer pre_load()
From: |
Gerd Hoffmann |
Subject: |
[PULL 13/14] pckbd: clear outport_present in outer pre_load() |
Date: |
Wed, 26 May 2021 16:06:26 +0200 |
From: Volker RĂ¼melin <vr_qemu@t-online.de>
The variable outport_present is a flag to show if the outport
subsection was loaded. Clear the outport_present flag in the
outer pre_load() function. This method is recommended in the QEMU
manual for developers in the chapter "Migration, Subsections".
Signed-off-by: Volker RĂ¼melin <vr_qemu@t-online.de>
Message-Id: <20210525181441.27768-12-vr_qemu@t-online.de>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
hw/input/pckbd.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/hw/input/pckbd.c b/hw/input/pckbd.c
index de867abc06b7..baba62f357a2 100644
--- a/hw/input/pckbd.c
+++ b/hw/input/pckbd.c
@@ -457,7 +457,6 @@ static void kbd_reset(void *opaque)
s->mode = KBD_MODE_KBD_INT | KBD_MODE_MOUSE_INT;
s->status = KBD_STAT_CMD | KBD_STAT_UNLOCKED;
s->outport = KBD_OUT_RESET | KBD_OUT_A20 | KBD_OUT_ONES;
- s->outport_present = false;
s->pending = 0;
kbd_deassert_irq(s);
if (s->throttle_timer) {
@@ -564,6 +563,7 @@ static int kbd_pre_load(void *opaque)
{
KBDState *s = opaque;
+ s->outport_present = false;
s->extended_state_loaded = false;
return 0;
}
@@ -574,7 +574,6 @@ static int kbd_post_load(void *opaque, int version_id)
if (!s->outport_present) {
s->outport = kbd_outport_default(s);
}
- s->outport_present = false;
s->pending = s->pending_tmp;
if (!s->extended_state_loaded) {
s->obsrc = s->status & KBD_STAT_OBF ?
--
2.31.1
- [PULL 02/14] ps2: fix mouse stream corruption, (continued)
- [PULL 02/14] ps2: fix mouse stream corruption, Gerd Hoffmann, 2021/05/26
- [PULL 03/14] ps2: don't raise an interrupt if queue is full, Gerd Hoffmann, 2021/05/26
- [PULL 05/14] pckbd: split out interrupt line changing code, Gerd Hoffmann, 2021/05/26
- [PULL 04/14] ps2: don't deassert irq twice if queue is empty, Gerd Hoffmann, 2021/05/26
- [PULL 06/14] pckbd: don't update OBF flags if KBD_STAT_OBF is set, Gerd Hoffmann, 2021/05/26
- [PULL 07/14] pckbd: PS/2 keyboard throttle, Gerd Hoffmann, 2021/05/26
- [PULL 09/14] pckbd: add controller response queue, Gerd Hoffmann, 2021/05/26
- [PULL 08/14] pckbd: add state variable for interrupt source, Gerd Hoffmann, 2021/05/26
- [PULL 11/14] pckbd: correctly disable PS/2 communication, Gerd Hoffmann, 2021/05/26
- [PULL 10/14] pckbd: add function kbd_pending(), Gerd Hoffmann, 2021/05/26
- [PULL 13/14] pckbd: clear outport_present in outer pre_load(),
Gerd Hoffmann <=
- [PULL 12/14] pckbd: remove duplicated keyboard and mouse defines, Gerd Hoffmann, 2021/05/26
- [PULL 14/14] hw/input/ps2: Use ps2_raise_irq() instead of open coding it, Gerd Hoffmann, 2021/05/26
- Re: [PULL 00/14] Input 20210526 patches, Peter Maydell, 2021/05/26