On Thu, Aug 01, 2013 at 05:16:07PM +0800, Xiao Guangrong wrote:
> On 07/31/2013 10:48 PM, Gleb Natapov wrote:
> > From: Nadav Har'El <[email protected]>
> >
> > KVM's existing shadow MMU code already supports nested TDP. To use it, we
> > need to set up a new "MMU context" for nested EPT, and create a few
> > callbacks
> > for it (nested_ept_*()). This context should also use the EPT versions of
> > the page table access functions (defined in the previous patch).
> > Then, we need to switch back and forth between this nested context and the
> > regular MMU context when switching between L1 and L2 (when L1 runs this L2
> > with EPT).
>
> This patch looks good to me.
>
> Reviewed-by: Xiao Guangrong <[email protected]>
>
> But i am confused that update_permission_bitmask() is not adjusted in this
> series. That function depends on kvm_read_cr4_bits(X86_CR4_SMEP) and
> is_write_protection(), these two functions should read the registers from
> L2 guest, using the L2 status to check L1's page table seems strange.
> The same issue is in nested npt. Anything i missed?
Good catch again. Looks like we need update_permission_bitmask_ept()
that uses different logic to calculate permissions.
--
Gleb.
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html