Re: [PATCH V2 07/12] KVM: TDX: restore host xsave state when exit from the guest TD

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2/27/2025 10:29 PM, Adrian Hunter wrote:
   +    vcpu->arch.cr4 = ~vcpu->arch.cr4_guest_rsvd_bits;
when userspace doesn't configure XFEATURE_MASK_PKRU in XFAM, it seems kvm_load_host_xsave_state() will skip restore host's PKRU value.
That's correct.

FYI, in this case, it's safe and functional though kvm_load_host_xsave_state() skips restoring the host's PKRU value. Because host's PKRU is not clobbered after TD exit when XFAM.PKU is 0. So no need to restore.




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux