From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeremy Fitzhardinge Subject: Re: pvops DomU kernels [was Re: "Hotplug Scripts not working ..." error on jaunty] Date: Fri, 23 Oct 2009 13:58:37 -0700 Message-ID: <4AE218FD.6040503@goop.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: Boris Derzhavets , Xen-devel , Dulloor , "Marc - A. Dahlhaus" List-Id: xen-devel@lists.xenproject.org On 10/23/09 13:48, Keir Fraser wrote: > On 23/10/2009 21:37, "Jeremy Fitzhardinge" wrote: > > >> Its not at all clear to me what Xen is objecting to here. There are a >> few paths where it can end up at could_not_pin in get_page_from_l1e(), >> but I don't know which one is happening here. I think it's the "if ( >> unlikely(real_pg_owner != pg_owner) )" conditional, but I don't know >> what real_pg_owner means here. >> >> Keir? >> > If you fail that test it means that the page does not belong to the domain > that the caller expected. In most cases, that means it was expected to > belong to the domain making the hypercall, but actually it does not belong > to it. The domain is calling update_va_mapping() on itself, and everything seems to be owned by the domain: (XEN) mm.c:840:d33 Error getting mfn 18c3 (pfn 21603) from L1 entry 80000000018c3061 for l1e_owner=33, pg_owner=33 The three paths that lead to could_not_pin are: if ( real_pg_owner == NULL ) goto could_not_pin; ... if ( unlikely(real_pg_owner != pg_owner) ) { if ( (pg_owner == l1e_owner) || !IS_PRIV_FOR(pg_owner, real_pg_owner) ) goto could_not_pin; pg_owner = real_pg_owner; } and if ( (l1f & _PAGE_RW) && ((l1e_owner == pg_owner) || !paging_mode_external(pg_owner)) && !get_page_type(page, PGT_writable_page) ) goto could_not_pin; The pte doesn't have RW set, so it must be one of the first two. Could it be read_pg_owner == NULL? J