Revert "libxl: fix libxl_domain_need_memory after 899433f149d"
authorWei Liu <wei.liu2@citrix.com>
Wed, 22 May 2019 08:08:41 +0000 (09:08 +0100)
committerWei Liu <wei.liu2@citrix.com>
Wed, 22 May 2019 08:08:41 +0000 (09:08 +0100)
This reverts commit 278c64519c661c851d37e2a929f006fb8a1dcd01.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
tools/libxl/libxl_mem.c

index 4446754186cf40851b500485923d91d85d3223b0..448a2af8fdf833cd5ec36a48edc97fd6392c1a9e 100644 (file)
@@ -457,24 +457,6 @@ int libxl_domain_need_memory(libxl_ctx *ctx,
     libxl_domain_build_info_init(b_info);
     libxl_domain_build_info_copy(ctx, b_info, b_info_in);
 
-    /*
-     * It has become a requirement that to figure out which QEMU to
-     * use, libxl will need to peek d_config's content. The code has
-     * been changed such that one will need to call
-     * libxl__domain_set_device_model before calling
-     * libxl__domain_build_info_setdefault inside libxl.
-     *
-     * This (problematic) public API is the only one which takes a
-     * b_info. Imposing the same requirement on the users of this
-     * public API will break them.
-     *
-     * Provide a compatibility setting for this function. The
-     * calculation doesn't really care which QEMU is set here, so we
-     * go with the upstream default.
-     */
-    if (!b_info->device_model_version)
-        b_info->device_model_version = LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN;
-
     rc = libxl__domain_build_info_setdefault(gc, b_info);
     if (rc) goto out;