qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [Spice-devel] [PATCH] spice: Use new SpiceImageCompress


From: Christophe Fergeau
Subject: Re: [Qemu-devel] [Spice-devel] [PATCH] spice: Use new SpiceImageCompression definition
Date: Tue, 27 Nov 2018 13:35:02 +0100
User-agent: Mutt/1.10.1 (2018-07-13)

hey,

On Mon, Nov 26, 2018 at 03:30:36PM +0000, Frediano Ziglio wrote:
> Definitions were updated by spice-server in patch de66161 included
> in 0.12.6 released on 12th June 2015.

QEMU's configure only checks for spice-server 0.12.0:

$pkg_config --atleast-version=0.12.0 spice-server

  if $pkg_config --atleast-version=0.12.0 spice-server && \
     $pkg_config --atleast-version=0.12.3 spice-protocol && \
     compile_prog "$spice_cflags" "$spice_libs" ; then
    spice="yes"
    libs_softmmu="$libs_softmmu $spice_libs"
    QEMU_CFLAGS="$QEMU_CFLAGS $spice_cflags"
    spice_protocol_version=$($pkg_config --modversion spice-protocol)
    spice_server_version=$($pkg_config --modversion spice-server)
  else
    if test "$spice" = "yes" ; then
      feature_not_found "spice" \
          "Install spice-server(>=0.12.0) and spice-protocol(>=0.12.3) devel"
    fi
    spice="no"
  fi

I don't know how far back QEMU wants to support spice-server.
Apart from this, the patch looks good to me.

Christophe

> 
> Signed-off-by: Frediano Ziglio <address@hidden>
> ---
>  ui/spice-core.c | 16 ++++++++--------
>  1 file changed, 8 insertions(+), 8 deletions(-)
> 
> diff --git a/ui/spice-core.c b/ui/spice-core.c
> index ebaae24643..2e6a255a35 100644
> --- a/ui/spice-core.c
> +++ b/ui/spice-core.c
> @@ -331,12 +331,12 @@ static const char *stream_video_names[] = {
>                 stream_video_names, ARRAY_SIZE(stream_video_names))
>  
>  static const char *compression_names[] = {
> -    [ SPICE_IMAGE_COMPRESS_OFF ]      = "off",
> -    [ SPICE_IMAGE_COMPRESS_AUTO_GLZ ] = "auto_glz",
> -    [ SPICE_IMAGE_COMPRESS_AUTO_LZ ]  = "auto_lz",
> -    [ SPICE_IMAGE_COMPRESS_QUIC ]     = "quic",
> -    [ SPICE_IMAGE_COMPRESS_GLZ ]      = "glz",
> -    [ SPICE_IMAGE_COMPRESS_LZ ]       = "lz",
> +    [ SPICE_IMAGE_COMPRESSION_OFF ]      = "off",
> +    [ SPICE_IMAGE_COMPRESSION_AUTO_GLZ ] = "auto_glz",
> +    [ SPICE_IMAGE_COMPRESSION_AUTO_LZ ]  = "auto_lz",
> +    [ SPICE_IMAGE_COMPRESSION_QUIC ]     = "quic",
> +    [ SPICE_IMAGE_COMPRESSION_GLZ ]      = "glz",
> +    [ SPICE_IMAGE_COMPRESSION_LZ ]       = "lz",
>  };
>  #define parse_compression(_name)                                        \
>      parse_name(_name, "image compression",                              \
> @@ -643,7 +643,7 @@ void qemu_spice_init(void)
>          *x509_cert_file = NULL,
>          *x509_cacert_file = NULL;
>      int port, tls_port, addr_flags;
> -    spice_image_compression_t compression;
> +    SpiceImageCompression compression;
>      spice_wan_compression_t wan_compr;
>      bool seamless_migration;
>  
> @@ -754,7 +754,7 @@ void qemu_spice_init(void)
>  #endif
>      }
>  
> -    compression = SPICE_IMAGE_COMPRESS_AUTO_GLZ;
> +    compression = SPICE_IMAGE_COMPRESSION_AUTO_GLZ;
>      str = qemu_opt_get(opts, "image-compression");
>      if (str) {
>          compression = parse_compression(str);
> -- 
> 2.17.2
> 
> _______________________________________________
> Spice-devel mailing list
> address@hidden
> https://lists.freedesktop.org/mailman/listinfo/spice-devel

Attachment: signature.asc
Description: PGP signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]