From: "Jan Beulich" Subject: Re: [V1 PATCH 09/11] PVH dom0: Add and remove foreign pages Date: Tue, 12 Nov 2013 16:58:04 +0000 Message-ID: <52826C2C0200007800102944@nat28.tlf.novell.com> References: <1383960215-22444-1-git-send-email-mukesh.rathor@oracle.com> <1383960215-22444-10-git-send-email-mukesh.rathor@oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1VgHI2-0005Dx-8H for xen-devel@lists.xenproject.org; Tue, 12 Nov 2013 16:58:10 +0000 In-Reply-To: <1383960215-22444-10-git-send-email-mukesh.rathor@oracle.com> Content-Disposition: inline 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 , keir.xen@gmail.com, tim@xen.org List-Id: xen-devel@lists.xenproject.org >>> On 09.11.13 at 02:23, Mukesh Rathor wrote: > +static int xenmem_add_foreign_to_pmap(domid_t foreign_domid, > + unsigned long fgfn, unsigned long gpfn) > +{ > + p2m_type_t p2mt, p2mt_prev; > + int rc = 0; > + unsigned long prev_mfn, mfn = 0; > + struct domain *fdom, *currd = current->domain; > + struct page_info *page = NULL; > + > + if ( currd->domain_id == foreign_domid || foreign_domid == DOMID_SELF || > + !is_pvh_domain(currd) ) > + return -EINVAL; > + > + if ( !is_hardware_domain(currd) || is_control_domain() Jan