Cleanly teardown and restore emulated device state on vm send/receive.
authordv <dv@openbsd.org>
Mon, 29 Mar 2021 13:09:41 +0000 (13:09 +0000)
committerdv <dv@openbsd.org>
Mon, 29 Mar 2021 13:09:41 +0000 (13:09 +0000)
commitbc11ef5ccacc5598ecad8b3b1211fad3d81e19b6
treef81178b3fc940f5e391b85ad4528dd3fddebaf60
parent1a998f47f259599f963b41c477a971bd036596bf
Cleanly teardown and restore emulated device state on vm send/receive.

This cleans up events on a pause or resume, but also fixes an issue
where the vm_pipe event channels are not properly reinitialized on a
received guest leading to broken serial console.

OK pd@, mlarkin@
usr.sbin/vmd/i8253.c
usr.sbin/vmd/mc146818.c
usr.sbin/vmd/ns8250.c