x86/Hyper-V: Expand definition of struct hv_vp_assist_page
Subsystems (3)
PATCH v2 1/1 x86/Hyper-V: Expand definition of struct hv_vp_assist_page
The struct hv_vp_assist_page has 24 bytes which is defined as u64[3], expand that to expose vtl_entry_reason, vtl_ret_x64rax and vtl_ret_x64rcx field. vtl_entry_reason is updated by hypervisor for the entry reason as to why the VTL was entered on the virtual processor.
Guest updates the vtl_ret_* fields to provide the register values to restore on VTL return. The specific register values that are restored which will be updated on vtl_ret_x64rax and vtl_ret_x64rcx. Also added the missing fields for synthetic_time_unhalted_timer_expired, virtualization_fault_information and intercept_message.
---
[v2]: Corrected vtl_entry_reson size from u8 to u32
arch/x86/include/asm/hyperv-tlfs.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-)
arch/x86/include/asm/hyperv-tlfs.h +10 -1
@@ -374,11 +374,20 @@ struct hv_nested_enlightenments_control {struct hv_vp_assist_page {__u32 apic_assist;__u32 reserved1; -__u64 vtl_control[3 ]; +__u32 vtl_entry_reason; +__u32 vtl_reserved; +__u64 vtl_ret_x64rax; +__u64 vtl_ret_x64rcx;struct hv_nested_enlightenments_control nested_control;__u8 enlighten_vmentry;__u8 reserved2[7 ];__u64 current_nested_vmcs; +__u8 synthetic_time_unhalted_timer_expired; +__u8 reserved3[7 ]; +__u8 virtualization_fault_information[40 ]; +__u8 reserved4[8 ]; +__u8 intercept_message[256 ]; +__u8 vtl_ret_actions[256 ]; } __packed;struct hv_enlightened_vmcs {
Signature · 1 line
1.8.3.1
Quoted 45 lines · Saurabh Sengar
The struct
hv_vp_assist_pagehas 24 bytes which is defined as u64[3], expand that to exposevtl_entry_reason,vtl_ret_x64raxandvtl_ret_x64rcxfield.vtl_entry_reasonis updated by hypervisor for the entry reason as to why the VTL was entered on the virtual processor.
Guest updates the vtl_ret_* fields to provide the register values to restore on VTL return. The specific register values that are restored which will be updated onvtl_ret_x64raxandvtl_ret_x64rcx. Also added the missing fields forsynthetic_time_unhalted_timer_expired,virtualization_fault_informationandintercept_message.Signed-off-by Saurabh Sengar <[email protected]>---
[v2]: Correctedvtl_entry_resonsize from u8 to u32arch/x86/include/asm/hyperv-tlfs.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-)arch/x86/include/asm/hyperv-tlfs.h +10
-1@@ -374,11 +374,20 @@ struct hv_nested_enlightenments_control {struct hv_vp_assist_page {__u32 apic_assist;__u32 reserved1; -__u64 vtl_control[3 ]; +__u32 vtl_entry_reason; +__u32 vtl_reserved; +__u64 vtl_ret_x64rax; +__u64 vtl_ret_x64rcx;struct hv_nested_enlightenments_control nested_control;__u8 enlighten_vmentry;__u8 reserved2[7 ];__u64 current_nested_vmcs; +__u8 synthetic_time_unhalted_timer_expired; +__u8 reserved3[7 ]; +__u8 virtualization_fault_information[40 ]; +__u8 reserved4[8 ]; +__u8 intercept_message[256 ]; +__u8 vtl_ret_actions[256 ]; } __packed;struct hv_enlightened_vmcs {Signature · 1 line
1.8.3.1
Wei Liu
maintainerQuoted 10 lines · Anirudh Rayabharam
Quoted 9 lines · Saurabh Sengar
The struct
hv_vp_assist_pagehas 24 bytes which is defined as u64[3], expand that to exposevtl_entry_reason,vtl_ret_x64raxandvtl_ret_x64rcxfield.vtl_entry_reasonis updated by hypervisor for the entry reason as to why the VTL was entered on the virtual processor.
Guest updates the vtl_ret_* fields to provide the register values to restore on VTL return. The specific register values that are restored which will be updated onvtl_ret_x64raxandvtl_ret_x64rcx. Also added the missing fields forsynthetic_time_unhalted_timer_expired,virtualization_fault_informationandintercept_message.
I did a bit of stylistic changes to the commit message and queued this up to hyperv-next. Thanks.