diff mbox series

[v2,4.15] libxl/Arm: correct xc_shadow_control() invocation to fix build

Message ID af81d6d5-5d2b-3db8-634f-17392ef328f9@suse.com (mailing list archive)
State New, archived
Headers show
Series [v2,4.15] libxl/Arm: correct xc_shadow_control() invocation to fix build | expand

Commit Message

Jan Beulich Oct. 12, 2022, 1:14 p.m. UTC
The backport didn't adapt to the earlier function prototype taking more
(unused here) arguments.

Fixes: c5215044578e ("xen/arm, libxl: Implement XEN_DOMCTL_shadow_op for Arm")
Signed-off-by: Jan Beulich <jbeulich@suse.com>
---
Also applicable to 4.14 and 4.13.
---
v2: Correct oversights.

-                              &shadow_mb, 0);
+                              NULL, 0, &shadow_mb, 0, NULL);
     if (r) {
         LOGED(ERROR, domid,
-              "Failed to set %u MiB shadow allocation", shadow_mb);
+              "Failed to set %lu MiB shadow allocation", shadow_mb);
         return ERROR_FAIL;
     }

Comments

Henry Wang Oct. 12, 2022, 1:16 p.m. UTC | #1
Hi Jan,

> -----Original Message-----
> From: Jan Beulich <jbeulich@suse.com>
> Subject: [PATCH v2][4.15] libxl/Arm: correct xc_shadow_control() invocation
> to fix build
> 
> The backport didn't adapt to the earlier function prototype taking more
> (unused here) arguments.
> 
> Fixes: c5215044578e ("xen/arm, libxl: Implement XEN_DOMCTL_shadow_op
> for Arm")
> Signed-off-by: Jan Beulich <jbeulich@suse.com>

Reviewed-by: Henry Wang <Henry.Wang@arm.com>

Kind regards,
Henry
Anthony PERARD Oct. 12, 2022, 2:08 p.m. UTC | #2
On Wed, Oct 12, 2022 at 01:16:47PM +0000, Henry Wang wrote:
> Hi Jan,
> 
> > -----Original Message-----
> > From: Jan Beulich <jbeulich@suse.com>
> > Subject: [PATCH v2][4.15] libxl/Arm: correct xc_shadow_control() invocation
> > to fix build
> > 
> > The backport didn't adapt to the earlier function prototype taking more
> > (unused here) arguments.
> > 
> > Fixes: c5215044578e ("xen/arm, libxl: Implement XEN_DOMCTL_shadow_op
> > for Arm")
> > Signed-off-by: Jan Beulich <jbeulich@suse.com>
> 
> Reviewed-by: Henry Wang <Henry.Wang@arm.com>

Acked-by: Anthony PERARD <anthony.perard@citrix.com>

Thanks,
diff mbox series

Patch

--- a/tools/libs/light/libxl_arm.c
+++ b/tools/libs/light/libxl_arm.c
@@ -132,7 +132,7 @@  int libxl__arch_domain_create(libxl__gc *gc,
                               uint32_t domid)
 {
     libxl_ctx *ctx = libxl__gc_owner(gc);
-    unsigned int shadow_mb = DIV_ROUNDUP(d_config->b_info.shadow_memkb, 1024);
+    unsigned long shadow_mb = DIV_ROUNDUP(d_config->b_info.shadow_memkb, 1024);
 
     int r = xc_shadow_control(ctx->xch, domid,
                               XEN_DOMCTL_SHADOW_OP_SET_ALLOCATION,