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

Re: [libvirt] [PATCH RESENT 10/12] RFC: libxl: special 'stubdom-dm' emulator to use qemu in stub domain



Marek Marczykowski wrote:
> Xen have feature of having device model in separate domain (called stub
> domain). It used to be enabled by special 'stubdom-dm' device model
> path.  Recent xl have separate config option for this feature
> (device_model_stubdomain_override), but I'm not sure if it worth
> introducing another xen-specific option in general domain XML syntax.
>
> Also use os->cmdline as extra arguments for qemu (for HVM only). This
> use of os->cmdline is rather dirty hack, but I haven't idea what better
> attribute use for it. Perhaps worth new attribute (in <emulator/>
> element?). Anyway os->cmdline was unused for HVM domains.
> ---
>  src/libxl/libxl_conf.c | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
>
> diff --git a/src/libxl/libxl_conf.c b/src/libxl/libxl_conf.c
> index 068a97a..181d344 100644
> --- a/src/libxl/libxl_conf.c
> +++ b/src/libxl/libxl_conf.c
> @@ -478,6 +478,18 @@ libxlMakeDomBuildInfo(libxlDriverPrivatePtr driver,
>              goto error;
>          }
>  
> +        if (def->emulator && strcmp(def->emulator, "stubdom-dm")==0) {
> +            libxl_defbool_set(&b_info->device_model_stubdomain, 1);
> +        }
>   

This is another case of libxl exposing some internal implementation
detail IMO. Apps know what emulator they want to use, they don't know
what special xen bit to set, e.g. stubdom, traditional, new, newer, ...

> +
> +        if (def->os.cmdline && def->os.cmdline[0]) {
> +            b_info->extra_hvm = virStringSplit(def->os.cmdline, " ", 0);
> +            if (b_info->extra_hvm == NULL) {
> +                virReportOOMError();
> +                goto error;
> +            }
> +        }
> +
>   

NACK to this change. qemu supports kernel, initrd, and append args for
direct kernel boot, which is useful when installing a guest OS. libxl
should support this for HVM guests. I'm pretty sure this works in the
legacy stack.

Regards,
Jim

>          /* Disable VNC and SDL until explicitly enabled */
>          libxl_defbool_set(&b_info->u.hvm.vnc.enable, 0);
>          libxl_defbool_set(&b_info->u.hvm.sdl.enable, 0);
>   


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