From: Tim Deegan Subject: Re: [RFC PATCH 14/16]: PVH xen: add xenmem_add_foreign_to_pmap() Date: Thu, 14 Feb 2013 10:22:25 +0000 Message-ID: <20130214102225.GA83752@ocelot.phlegethon.org> References: <20130111181103.5bfeed98@mantra.us.oracle.com> <20130124173118.GN20551@ocelot.phlegethon.org> <20130211181824.169b9d05@mantra.us.oracle.com> <20130213183425.0d17c236@mantra.us.oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <20130213183425.0d17c236@mantra.us.oracle.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Mukesh Rathor Cc: "Xen-devel@lists.xensource.com" List-Id: xen-devel@lists.xenproject.org At 18:34 -0800 on 13 Feb (1360780465), Mukesh Rathor wrote: > On Mon, 11 Feb 2013 18:18:24 -0800 > Mukesh Rathor wrote: > > > On Thu, 24 Jan 2013 17:31:18 +0000 > > Tim Deegan wrote: > > > > > At 18:11 -0800 on 11 Jan (1357927863), Mukesh Rathor wrote: > > > > > > > + /* qemu, running on PVH dom0, mapping hvm domain's io pages > > > > during domain > > > > + * creation, doesn't have mfns in the HAP table */ > > > > + if ( !mfn_valid(mfn) && p2m_is_mmio(p2mt) ) { > > > > > > This test should be for == p2m_mmio_direct; we don't want to try > > > mapping p2m_mmio_dm areas. > > > > Yup. Done. > > No, qemu is changing the mem type for these pages, so I need to dig > into understanding what it's trying to do there. But the above, I don't > think is correct. Xen returns p2m type of dm, but I don't think I'm > looking at right mfn's here for this qemu special case. Basically, it's > during hvm guest creation on PVH dom0 that qemu accesses some addresses > that are not mapped. It may be that the memory is genuinely not there - since qemu doesn't build the guest itself it doesn't necessarily know exactly where the builder put all the memory. If that's the case, then just failing the mapping is the right response. Tim.