Hi Jan,
If we want to provide useful nested SVM support, this must be feasible.
If there is a bug, it has to be fixed.
I was more concerned about if it is supported (and it means I do
something wrong), or if it is not supported (at least, now).
Maybe you can describe how you configured the involved units (NPT
structures, guest / host PAR, MTRR etc.).
I've tried different combinations, but to be specific:
- NPT: four-level long-mode page tables; all PTEs except terminal have
U,R,P bits set (0x07), as per APMv2 15.25.5
- APIC page pte; physical address 0xfee00000, flags: PAT, PWT, PCD, U, P
(0x9D)
- guest PAT and host PAT are the same, 0x7010600070106 (as set by the
Linux kernel). Guest PAT is stored in VMCB; host PAT is restored at each
#VMEXIT.
- MTRRs. No changes to what Linux use prior to VM entry here; #0 (base
0x80000000, mask 0xFF80000000) uncacheable, others are disabled.
I also noticed that setting PAT MSR from the nested hypervisor leaves
high word unassigned, i.e. the code like this:
mov $0x70106, %rax
mov %rax, %rdx
mov $0x0277, %rcx
wrmsr
rdmsr
yields %rax = 0, %rdx = 0x70106.
Even better would be a test case based on kvm-unit-tests (see [1],
Will have a look at it, thanks.
--
Best regards,
Valentine Sinitsyn
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html