lkml.org 
[lkml]   [2021]   [Sep]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 01/16] KVM: MMU: pass unadulterated gpa to direct_page_fault
On Sat, Aug 07, 2021, Paolo Bonzini wrote:
> Do not bother removing the low bits of the gpa. This masking dates back
> to the very first commit of KVM but it is unnecessary---or even
> problematic, because the gpa is later used to fill in the MMIO page cache.

I don't disagree with the code change, but I don't see how stripping the offset
can be problematic for the MMIO page cache. I assume you're referring to
handle_abnormal_pfn() -> vcpu_cache_mmio_info(). The "gva" is masked with
PAGE_MASK, i.e. the offset is stripped anyways. And fundamentally, that cache
is tied to the granularity of the memslots, tracking the offset would be wrong.

\
 
 \ /
  Last update: 2021-09-02 00:55    [W:0.066 / U:0.504 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site