[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH 1/2] libxc: support to resume uncooperative HVM guests



On Fri, Apr 01, 2016 at 05:59:47PM +0200, Olaf Hering wrote:
> On Thu, Mar 31, Wei Liu wrote:
> 
> > +static int xc_domain_resume_hvm(xc_interface *xch, uint32_t domid)
> >  #if defined(__i386__) || defined(__x86_64__)
> > +        return xc_domain_resume_hvm(xch, domid);
> 
> This causes a build error no non-x86.
> 
> [  334s] xc_resume.c:112:12: error: 'xc_domain_resume_hvm' defined but not 
> used [-Werror=unused-function]
> [  334s]  static int xc_domain_resume_hvm(xc_interface *xch, uint32_t domid)
> 

Does this work?


From 6f3252a82168d0025c585dbbaf5817f42f5d1e85 Mon Sep 17 00:00:00 2001
From: Wei Liu <wei.liu2@xxxxxxxxxx>
Date: Fri, 1 Apr 2016 17:07:52 +0100
Subject: [PATCH] libxc: xc_domain_resume_hvm is used by x86 only

The call site is enclosed by x86 define guards.

Signed-off-by: Wei Liu <wei.liu2@xxxxxxxxxx>
---
 tools/libxc/xc_resume.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tools/libxc/xc_resume.c b/tools/libxc/xc_resume.c
index 6bf7d9c..2b6c308 100644
--- a/tools/libxc/xc_resume.c
+++ b/tools/libxc/xc_resume.c
@@ -109,6 +109,7 @@ static int xc_domain_resume_cooperative(xc_interface *xch, 
uint32_t domid)
     return do_domctl(xch, &domctl);
 }
 
+#if defined(__i386__) || defined(__x86_64__)
 static int xc_domain_resume_hvm(xc_interface *xch, uint32_t domid)
 {
     DECLARE_DOMCTL;
@@ -128,6 +129,7 @@ static int xc_domain_resume_hvm(xc_interface *xch, uint32_t 
domid)
     domctl.domain = domid;
     return do_domctl(xch, &domctl);
 }
+#endif
 
 static int xc_domain_resume_any(xc_interface *xch, uint32_t domid)
 {
-- 
2.1.4

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.