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

Re: [Xen-devel] [PATCH v2] libxl: use qemu-xen (upstream QEMU) as device model by default



On Tue, 2012-12-04 at 12:58 +0000, Stefano Stabellini wrote:
> diff --git a/docs/man/xl.cfg.pod.5 b/docs/man/xl.cfg.pod.5
> index fe4fac9..69a38b9 100644
> --- a/docs/man/xl.cfg.pod.5
> +++ b/docs/man/xl.cfg.pod.5
> @@ -1132,15 +1132,15 @@ guest. Valid values are:
>  
>  =over 4
>  
> -=item B<qemu-xen-traditional>
> +=item B<qemu-xen>
>  
> -Use the device-model based upon the historical Xen fork of Qemu.  This
> -device-model is currently the default.
> +use the device-model merged into the upstream QEMU project.

Can you correct to "Use" as you move it please.

> +This device-model is the default for Linux dom0.
>  
> -=item B<qemu-xen>
> +=item B<qemu-xen-traditional>
>  
> -use the device-model merged into the upstream QEMU project.  This
> -device-model will become the default in a future version of Xen.
> +Use the device-model based upon the historical Xen fork of Qemu.
> +This device-model is still the default for NetBSD dom0.

Does that look like changing for 4.3?

> diff --git a/tools/libxl/libxl_create.c b/tools/libxl/libxl_create.c
> index 9d20086..6ec543a 100644
> --- a/tools/libxl/libxl_create.c
> +++ b/tools/libxl/libxl_create.c
> @@ -143,8 +143,7 @@ int libxl__domain_build_info_setdefault(libxl__gc *gc,
>  
>      if (!b_info->device_model_version) {
>          if (b_info->type == LIBXL_DOMAIN_TYPE_HVM)
> -            b_info->device_model_version =
> -                LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN_TRADITIONAL;
> +            b_info->device_model_version = libxl__default_device_model(gc);

For PV we stat() the executable before using it -- I don't remember why
but should we be doing the same here?

Also, will this not break things for people with
"device_model_stubdomain_override = 1" (but nothing else) in their
configuration?

I think the logic needs to be (perhaps in Linux's
libxl__default_device_model(gc) only)
        if (libxl_defbool_val(b_info->device_model_stubdomain)
                LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN_TRADITIONAL;
        else
                LIBXL_DEVICE_MODEL_VERSION_QEMU_XEN;

? At least until we have upstream stubdoms in some form.

>          else {
>              const char *dm;
>              int rc;
> diff --git a/tools/libxl/libxl_internal.h b/tools/libxl/libxl_internal.h
> index cba3616..0ea11d1 100644
> --- a/tools/libxl/libxl_internal.h
> +++ b/tools/libxl/libxl_internal.h
> @@ -1557,6 +1557,10 @@ _hidden libxl__json_object 
> *libxl__json_parse(libxl__gc *gc_opt, const char *s);
>    /* Based on /local/domain/$domid/dm-version xenstore key
>     * default is qemu xen traditional */
>  _hidden int libxl__device_model_version_running(libxl__gc *gc, uint32_t 
> domid);
> +  /* Return the system-wide default device model:
> +   * qemu-xen for Linux, qemu-xen-traditional for NetBSD.

I bet you someone forgets to update this when NetBSD changes ;-)

> +   */
> +_hidden libxl_device_model_version libxl__default_device_model(libxl__gc 
> *gc);
>  
>  /* Check how executes hotplug script currently */
>  int libxl__hotplug_settings(libxl__gc *gc, xs_transaction_t t);



_______________________________________________
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®.