hv: console: switch back to HV shell on VM pause
A VM may transition to VM_PAUSED state while its console is being used.
Jump back to the HV shell if this happens so the console does not appear
stuck.
Acked-by: Eddie Dong
@@ -98,7 +98,7 @@ static struct acrn_vuart *vuart_console_active(void)
if (console_vmid < CONFIG_MAX_VM_NUM) {
vm = get_vm_from_vmid(console_vmid);
- if (!is_poweroff_vm(vm)) {
+ if (!is_paused_vm(vm) && !is_poweroff_vm(vm)) {
vu = vm_console_vuart(vm);
} else {
/* Console vm is invalid, switch back to HV-Shell */
