Re: [PATCH v6 08/18] KVM: x86/mmu: Support GFN direct bits

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

 



On Sun, Dec 22, 2024, Paolo Bonzini wrote:
> Since TDX only needs to shift the mapping like this for the shared bit,
> which is mapped as the normal TDP root, add a "gfn_direct_bits" field to
> the kvm_arch structure for each VM with a default value of 0. It will
> have the bit set at the position of the GPA shared bit in GFN through TD
> specific initialization code. Keep TDX specific concepts out of the MMU
> code by not naming it "shared".

...

> diff --git a/arch/x86/include/asm/kvm_host.h b/arch/x86/include/asm/kvm_host.h
> index cae88f023caf..95f2b0890a58 100644
> --- a/arch/x86/include/asm/kvm_host.h
> +++ b/arch/x86/include/asm/kvm_host.h
> @@ -1542,6 +1542,8 @@ struct kvm_arch {
>  	 */
>  #define SPLIT_DESC_CACHE_MIN_NR_OBJECTS (SPTE_ENT_PER_PAGE + 1)
>  	struct kvm_mmu_memory_cache split_desc_cache;
> +

Not urgent, i.e. shouldn't hold up anything, but can someone add a comment here
to explain what "direct" means?  I know all of the concepts and code in play,
and I still don't really know what "direct" means in this context.  I doubt
others will fair much better :-)

> +	gfn_t gfn_direct_bits;
>  };




[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