lkml.org 
[lkml]   [2017]   [Apr]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [Xen-devel] xen_exit_mmap() questions
>>> On 27.04.17 at 02:55, <boris.ostrovsky@oracle.com> wrote:
> The point of CR3 loading here, I believe, is to make sure the hypervisor
> knows that the (v)CPU is no longer using the the mm's cr3 (we are
> loading swapper_pgdir here).

Correct, or else there would still be a non-zero refcount for the
page tables hanging off of that CR3, disallowing those pages to
become writable, and in turn disallowing the use of direct writes
instead of hypercalls to clear the individual entries (or to be
precise, direct writes would still be allowed, but their use would
be even slower than using hypercalls because they would trap
into the hypervisor for emulation).

Jan

\
 
 \ /
  Last update: 2017-04-27 09:40    [W:0.151 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site