From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Kiszka Subject: Re: Nested paging in nested SVM setup Date: Wed, 18 Jun 2014 14:47:41 +0200 Message-ID: <53A18A6D.2050407@siemens.com> References: <53A179C4.9060203@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit To: Valentine Sinitsyn , kvm@vger.kernel.org Return-path: Received: from goliath.siemens.de ([192.35.17.28]:49999 "EHLO goliath.siemens.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S966056AbaFRMro (ORCPT ); Wed, 18 Jun 2014 08:47:44 -0400 In-Reply-To: <53A179C4.9060203@gmail.com> Sender: kvm-owner@vger.kernel.org List-ID: On 2014-06-18 13:36, Valentine Sinitsyn wrote: > Hi all, > > I'm using a KVM/Qemu nested SVM setup to debug another hypervisor > (Jailhouse) I contribute to. IOW, the scheme is: AMD64 Linux host > running [paravirtualized] AMD64 Linux guest (the same kernel as the > host) running Jailhouse. > > Jailhouse, in turn, uses Nested Paging to virtualize xAPIC: APIC page > (0xfee00000, no APIC remapping) is mapped read-only into Jailhouse's > guests. This of course implies that APIC page appears to Jailhouse > guests as uncacheable (UC). > > Is it achievable in the setup I described, or do I need to run my code > on a real hardware to make the APIC page accesses in Jailhouse guests > uncacheable? If we want to provide useful nested SVM support, this must be feasible. If there is a bug, it has to be fixed. Maybe you can describe how you configured the involved units (NPT structures, guest / host PAR, MTRR etc.). Even better would be a test case based on kvm-unit-tests (see [1], x86/svm.c) that replicates the observed behavior. If it reveals a bug, this test would be very valuable for making sure it remains fixed (once that is done). Jan [1] https://git.kernel.org/cgit/virt/kvm/kvm-unit-tests.git -- Siemens AG, Corporate Technology, CT RTC ITP SES-DE Corporate Competence Center Embedded Linux