vmm: vm: fix test_vm test case

We should break out from the loop after getting the HLT exit, otherwise
the VM hangs forever.

Signed-off-by: Wei Liu <liuwe@microsoft.com>
This commit is contained in:
Wei Liu 2020-06-11 16:42:29 +00:00 committed by Samuel Ortiz
parent 52b839694d
commit 5ebd02a572

View File

@ -1493,6 +1493,7 @@ pub fn test_vm() {
VcpuExit::Debug => {}
VcpuExit::Hlt => {
println!("HLT");
break;
}
VcpuExit::IrqWindowOpen => {}
VcpuExit::Shutdown => {}