From 0cf51428956d830bd18d571876786852ea590ed3 Mon Sep 17 00:00:00 2001 From: Jason Chen CJ Date: Wed, 30 May 2018 19:40:54 +0800 Subject: [PATCH] remove unused vm_state_info vm_state_info in struct vm_arch is not used, remove it Signed-off-by: Jason Chen CJ Acked-by: Xu, Anthony Acked-by: Eddie Dong --- hypervisor/arch/x86/guest/vm.c | 2 -- hypervisor/include/arch/x86/guest/vm.h | 9 --------- 2 files changed, 11 deletions(-) diff --git a/hypervisor/arch/x86/guest/vm.c b/hypervisor/arch/x86/guest/vm.c index 1ef2d58cf..5ec76f20f 100644 --- a/hypervisor/arch/x86/guest/vm.c +++ b/hypervisor/arch/x86/guest/vm.c @@ -61,8 +61,6 @@ static void init_vm(struct vm_description *vm_desc, vm_handle->hw.num_vcpus = vm_desc->vm_hw_num_cores; vm_handle->hw.exp_num_vcpus = vm_desc->vm_hw_num_cores; } - vm_handle->state_info.privilege = vm_desc->vm_state_info_privilege; - vm_handle->state_info.boot_count = 0; } /* return a pointer to the virtual machine structure associated with diff --git a/hypervisor/include/arch/x86/guest/vm.h b/hypervisor/include/arch/x86/guest/vm.h index 0ceb83c5f..bca640039 100644 --- a/hypervisor/include/arch/x86/guest/vm.h +++ b/hypervisor/include/arch/x86/guest/vm.h @@ -108,14 +108,6 @@ enum vm_state { VM_STATE_UNKNOWN }; -/* Structure for VM state information */ -struct vm_state_info { - enum vm_state state; /* State of the VM */ - unsigned int privilege; /* Privilege level of the VM */ - unsigned int boot_count;/* Number of times the VM has booted */ - -}; - struct vm_arch { uint64_t guest_init_pml4;/* Guest init pml4 */ /* EPT hierarchy for Normal World */ @@ -163,7 +155,6 @@ struct vm { struct vm_sw_info sw; /* Reference to SW associated with this VM */ struct vm_pm_info pm; /* Reference to this VM's arch information */ struct vm_arch arch_vm; /* Reference to this VM's arch information */ - struct vm_state_info state_info;/* State info of this VM */ enum vm_state state; /* VM state */ struct vcpu *current_vcpu; /* VCPU that caused vm exit */ void *vuart; /* Virtual UART */