Currently libxl_domain_setmaxmem doesn't do anything, but it should call
xc_domain_setmaxmem to enforce the new "xen maximum" target for the
domain (see tools/libxl/libxl_memory.txt).
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
LIBXL__LOG_ERRNO(ctx, LIBXL__LOG_ERROR, "memory_static_max must be greater than or or equal to memory_dynamic_max\n");
goto out;
}
+ rc = xc_domain_setmaxmem(ctx->xch, domid, max_memkb + LIBXL_MAXMEM_CONSTANT);
+ if (rc != 0) {
+ LIBXL__LOG_ERRNO(ctx, LIBXL__LOG_ERROR,
+ "xc_domain_setmaxmem domid=%d memkb=%d failed "
+ "rc=%d\n", domid, max_memkb + LIBXL_MAXMEM_CONSTANT, rc);
+ goto out;
+ }
rc = 0;
out: