[lkml]   [2024]   [May]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 04/16] KVM: x86/mmu: Add address conversion functions for TDX shared bit of GPA
On Thu, 2024-05-16 at 13:04 +1200, Huang, Kai wrote:
> I really don't see difference between ...
>         is_private_mem(gpa)
> ... and
>         is_private_gpa(gpa)
> If it confuses me, it can confuses other people.

Again, point taken. I'll try to think of a better name. Please share if you do.

> The point is there's really no need to distinguish the two.  The GPA is
> only meaningful when it refers to the memory that it points to.
> So far I am not convinced we need this helper, because such info we can
> already get from:
>    1) fault->is_private;
>    2) Xarray which records memtype for given GFN.
> So we should just get rid of it.

Kai, can you got look through the dev branch a bit more before making the same
point on every patch?

kvm_is_private_gpa() is used to set PFERR_PRIVATE_ACCESS, which in turn sets
fault->is_private. So you are saying we can use these other things that are
dependent on it. Look at the other callers too.
 \ /
  Last update: 2024-05-27 18:29    [W:0.087 / U:0.420 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site