From mboxrd@z Thu Jan 1 00:00:00 1970 From: Samuel Thibault Subject: Re: [PATCH] libxc: Use vcpu_guest_context_any_t instead of two pages Date: Wed, 27 Aug 2008 15:45:57 +0100 Message-ID: <20080827144557.GT4535@implementation.uk.xensource.com> References: <20080827113839.GP4535@implementation.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Return-path: Content-Disposition: inline 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: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Keir Fraser, le Wed 27 Aug 2008 14:58:57 +0100, a =E9crit : > This patch doesn't apply. You must have other patches layered underneat= h it. Oops sorry, actually I had just mistakenly lowered all cases in the patch (powerful editors...) libxc: Use vcpu_guest_context_any_t instead of two pages Signed-off-by: Samuel Thibault diff -r 14a9a1629590 tools/libxc/xc_dom_boot.c --- a/tools/libxc/xc_dom_boot.c wed aug 27 10:26:50 2008 +0100 +++ b/tools/libxc/xc_dom_boot.c wed aug 27 12:07:28 2008 +0100 @@ -187,7 +187,7 @@ int xc_dom_boot_image(struct xc_dom_imag int xc_dom_boot_image(struct xc_dom_image *dom) { DECLARE_DOMCTL; - void *ctxt; + vcpu_guest_context_any_t ctxt; int rc; =20 xc_dom_printf("%s: called\n", __FUNCTION__); @@ -245,12 +245,11 @@ int xc_dom_boot_image(struct xc_dom_imag return rc; =20 /* let the vm run */ - ctxt =3D xc_dom_malloc(dom, PAGE_SIZE * 2 /* FIXME */ ); - memset(ctxt, 0, PAGE_SIZE * 2); - if ( (rc =3D dom->arch_hooks->vcpu(dom, ctxt)) !=3D 0 ) + memset(&ctxt, 0, sizeof(ctxt)); + if ( (rc =3D dom->arch_hooks->vcpu(dom, &ctxt)) !=3D 0 ) return rc; xc_dom_unmap_all(dom); - rc =3D launch_vm(dom->guest_xc, dom->guest_domid, ctxt); + rc =3D launch_vm(dom->guest_xc, dom->guest_domid, &ctxt); =20 return rc; }