Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

mshv: Add nested virtualization creation flag

Introduce HV_PARTITION_CREATION_FLAG_NESTED_VIRTUALIZATION_CAPABLE to
indicate support for nested virtualization during partition creation.

This enables clearer configuration and capability checks for nested
virtualization scenarios.

Signed-off-by: Stanislav Kinsburskii <skinsburskii@linux.microsoft.com>
Signed-off-by: Muminul Islam <muislam@microsoft.com>
Signed-off-by: Wei Liu <wei.liu@kernel.org>

authored by

Muminul Islam and committed by
Wei Liu
a284dbc9 30d25a8f

+4
+2
drivers/hv/mshv_root_main.c
··· 1947 1947 *pt_flags |= HV_PARTITION_CREATION_FLAG_X2APIC_CAPABLE; 1948 1948 if (args.pt_flags & BIT_ULL(MSHV_PT_BIT_GPA_SUPER_PAGES)) 1949 1949 *pt_flags |= HV_PARTITION_CREATION_FLAG_GPA_SUPER_PAGES_ENABLED; 1950 + if (args.pt_flags & BIT(MSHV_PT_BIT_NESTED_VIRTUALIZATION)) 1951 + *pt_flags |= HV_PARTITION_CREATION_FLAG_NESTED_VIRTUALIZATION_CAPABLE; 1950 1952 1951 1953 isol_props->as_uint64 = 0; 1952 1954
+1
include/hyperv/hvhdk.h
··· 335 335 #define HV_PARTITION_ISOLATION_HOST_TYPE_RESERVED 0x2 336 336 337 337 /* Note: Exo partition is enabled by default */ 338 + #define HV_PARTITION_CREATION_FLAG_NESTED_VIRTUALIZATION_CAPABLE BIT(1) 338 339 #define HV_PARTITION_CREATION_FLAG_GPA_SUPER_PAGES_ENABLED BIT(4) 339 340 #define HV_PARTITION_CREATION_FLAG_EXO_PARTITION BIT(8) 340 341 #define HV_PARTITION_CREATION_FLAG_LAPIC_ENABLED BIT(13)
+1
include/uapi/linux/mshv.h
··· 27 27 MSHV_PT_BIT_X2APIC, 28 28 MSHV_PT_BIT_GPA_SUPER_PAGES, 29 29 MSHV_PT_BIT_CPU_AND_XSAVE_FEATURES, 30 + MSHV_PT_BIT_NESTED_VIRTUALIZATION, 30 31 MSHV_PT_BIT_COUNT, 31 32 }; 32 33