lkml.org 
[lkml]   [2022]   [Apr]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [RFC PATCH v5 033/104] KVM: x86: Add infrastructure for stolen GPA bits
From
On 4/6/22 04:23, Kai Huang wrote:
>>
>>>>
>>>>
>>>> - gfn = gpte_to_gfn(gpte);
>>>> + gfn = gpte_to_gfn(vcpu, gpte);
>>>> pte_access = sp->role.access;
>>>> pte_access &= FNAME(gpte_access)(gpte);
>>>> FNAME(protect_clean_gpte)(vcpu->arch.mmu, &pte_access, gpte);
>>>
>>> In commit message you mentioned "Don't support stolen bits for shadow EPT" (you
>>> actually mean shadow MMU I suppose), yet there's bunch of code change to shadow
>>> MMU.
>>
>> It's a bit ugly, but it's uglier to keep two versions of gpte_to_gfn.
>
> gpte_to_gfn() is only used in paging_tmpl.h. Could you elaborate why we need to
> keep two versions of it?

You're right. Yeah, considering page table walks are not supported when
private memory is available, it shouldn't be necessary to change
paging_tmpl.h.

Paolo

\
 
 \ /
  Last update: 2022-04-06 15:51    [W:1.046 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site