diff mbox

[1/2] libxc: support to resume uncooperative HVM guests

Message ID 20160401161055.GP27636@citrix.com (mailing list archive)
State New, archived
Headers show

Commit Message

Wei Liu April 1, 2016, 4:10 p.m. UTC
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@citrix.com>
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@citrix.com>
---
 tools/libxc/xc_resume.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Olaf Hering April 1, 2016, 4:42 p.m. UTC | #1
On Fri, Apr 01, Wei Liu wrote:

> Does this work?

Most likely yes.

Olaf
Olaf Hering April 1, 2016, 7:41 p.m. UTC | #2
On Fri, Apr 01, Olaf Hering wrote:

> On Fri, Apr 01, Wei Liu wrote:
> 
> > Does this work?
> 
> Most likely yes.

Yes, this change fixes it. Thanks.
There is another failure on arm now, see the other mail "arm: staging
build error in libxl helper_setcallbacks_restore".

Olaf
diff mbox

Patch

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)
 {