qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] Set runstate to RUN_STATE_RESTORE_VM when started with "-loadvm"
@ 2022-08-13  1:10 Joelle van Dyne
  2022-08-13  1:10 ` [PATCH 1/3] Revert "usbredir: avoid queuing hello packet on snapshot restore" Joelle van Dyne
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Joelle van Dyne @ 2022-08-13  1:10 UTC (permalink / raw)
  To: qemu-devel

Previously, there was a bug in usbredir which prevented "-loadvm" from working
because libusbredir's usbredirparser_unserialize() fails when a HELLO packet is
sent as part of the device's initalization.

The fix was to not send HELLO when in the RUN_STATE_PRELAUNCH state. However,
recently we found that this breaks when QEMU is started with "-S" because it
is in the RUN_STATE_PRELAUNCH state while halted before boot as well.

This patch attempts to re-fix the issue by setting the run state to
RUN_STATE_RESTORE_VM when started with "-loadvm" and recognizing that state
in usbredir's initalization.

To make sure there's no unintended side effects, we searched for
"RUN_STATE_RESTORE_VM" in the code base and found only references in
migration/savevm.c, monitor/hmp-cmds.c, and replay/replay-debugging.c. None of
these seems to be affected by RUN_STATE_RESTORE_VM before RUN_STATE_RUNNING.

Joelle van Dyne (3):
  Revert "usbredir: avoid queuing hello packet on snapshot restore"
  vl: on -loadvm set run state to "restore-vm"
  usbredir: avoid queuing hello packet on snapshot restore

 hw/usb/redirect.c  | 2 +-
 softmmu/runstate.c | 1 +
 softmmu/vl.c       | 3 +++
 3 files changed, 5 insertions(+), 1 deletion(-)

-- 
2.28.0



^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2022-11-21 12:27 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-08-13  1:10 [PATCH 0/3] Set runstate to RUN_STATE_RESTORE_VM when started with "-loadvm" Joelle van Dyne
2022-08-13  1:10 ` [PATCH 1/3] Revert "usbredir: avoid queuing hello packet on snapshot restore" Joelle van Dyne
2022-11-21 12:26   ` Ján Tomko
2022-08-13  1:10 ` [PATCH 2/3] vl: on -loadvm set run state to "restore-vm" Joelle van Dyne
2022-08-22 10:11   ` Daniel P. Berrangé
2022-10-29 23:35     ` Joelle van Dyne
2022-08-13  1:10 ` [PATCH 3/3] usbredir: avoid queuing hello packet on snapshot restore Joelle van Dyne
2022-08-13  5:30   ` Victor Toso
2022-08-13  5:33     ` Joelle van Dyne
2022-08-13  5:50       ` Victor Toso
2022-08-13  5:57         ` Joelle van Dyne
2022-08-13  7:12           ` Victor Toso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).