WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH 05/14] libxl: disks: expose new "script" paramete

On Thu, 2011-05-12 at 15:36 +0100, Ian Jackson wrote:
> This is not currently implemented.  Applications setting it to
> anything but NULL will cause an error.  Code to set it from xl
> configuration files will appear later in this series.
> 
> Signed-off-by: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>

Acked-by: Ian Campbell <ian.campbell@xxxxxxxxxx>

Is there (going to be) a spec of what such scripts must do, are and are
not allowed to do etc? (apologies if this comes later in the series)

> ---
>  tools/libxl/libxl.c   |    7 +++++++
>  tools/libxl/libxl.idl |    1 +
>  2 files changed, 8 insertions(+), 0 deletions(-)
> 
> diff --git a/tools/libxl/libxl.c b/tools/libxl/libxl.c
> index d4a47f2..ac7b68a 100644
> --- a/tools/libxl/libxl.c
> +++ b/tools/libxl/libxl.c
> @@ -968,6 +968,13 @@ int libxl_device_disk_add(libxl_ctx *ctx, uint32_t 
> domid, libxl_device_disk *dis
>          goto out_free;
>      }
>  
> +    if (disk->script) {
> +        LIBXL__LOG(ctx, LIBXL__LOG_ERROR, "External block scripts"
> +                   " not yet supported, sorry");
> +        rc = ERROR_INVAL;
> +        goto out_free;
> +    }
> +
>      devid = libxl__device_disk_dev_number(disk->vdev, NULL, NULL);
>      if (devid==-1) {
>          LIBXL__LOG(ctx, LIBXL__LOG_ERROR, "Invalid or unsupported"
> diff --git a/tools/libxl/libxl.idl b/tools/libxl/libxl.idl
> index a5be66f..546cd3c 100644
> --- a/tools/libxl/libxl.idl
> +++ b/tools/libxl/libxl.idl
> @@ -261,6 +261,7 @@ libxl_device_disk = Struct("device_disk", [
>      ("vdev", string),
>      ("backend", libxl_disk_backend),
>      ("format", libxl_disk_format),
> +    ("script", string),
>      ("unpluggable", integer),
>      ("readwrite", integer),
>      ("is_cdrom", integer),



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel