qemu-s390x
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [RFC PATCH 1/3] hw/intc/s390_flic: Migrate pending state


From: David Hildenbrand
Subject: Re: [RFC PATCH 1/3] hw/intc/s390_flic: Migrate pending state
Date: Sun, 26 May 2024 17:53:41 +0200
User-agent: Mozilla Thunderbird

Am 25.05.24 um 15:12 schrieb Nicholas Piggin:
The flic pending state is not migrated, so if the machine is migrated
while an interrupt is pending, it can be lost. This shows up in
qtest migration test, an extint is pending (due to console writes?)
and the CPU waits via s390_cpu_set_psw and expects the interrupt to
wake it. However when the flic pending state is lost, s390_cpu_has_int
returns false, so s390_cpu_exec_interrupt falls through to halting
again.

Fix this by migrating pending. This prevents the qtest from hanging.
Does service_param need to be migrated? Or the IO lists?

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
---
  hw/intc/s390_flic.c | 1 +
  1 file changed, 1 insertion(+)

diff --git a/hw/intc/s390_flic.c b/hw/intc/s390_flic.c
index 6771645699..b70cf2295a 100644
--- a/hw/intc/s390_flic.c
+++ b/hw/intc/s390_flic.c
@@ -369,6 +369,7 @@ static const VMStateDescription qemu_s390_flic_vmstate = {
      .fields = (const VMStateField[]) {
          VMSTATE_UINT8(simm, QEMUS390FLICState),
          VMSTATE_UINT8(nimm, QEMUS390FLICState),
+        VMSTATE_UINT32(pending, QEMUS390FLICState),
          VMSTATE_END_OF_LIST()
      }
  };

Likely you have to handle this using QEMU compat machines.

--
Thanks,

David / dhildenb




reply via email to

[Prev in Thread] Current Thread [Next in Thread]