xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: Paul Durrant <paul.durrant@citrix.com>
Cc: Ian Jackson <ian.jackson@eu.citrix.com>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	Keir Fraser <keir@xen.org>, Jan Beulich <jbeulich@suse.com>,
	xen-devel@lists.xen.org
Subject: Re: [PATCH v5 1/3] x86/viridian: Re-purpose the HVM parameter to be a feature mask
Date: Tue, 26 Aug 2014 21:28:30 +0100	[thread overview]
Message-ID: <1409084910.28009.33.camel@citrix.com> (raw)
In-Reply-To: <1407244035-25977-2-git-send-email-paul.durrant@citrix.com>

On Tue, 2014-08-05 at 14:07 +0100, Paul Durrant wrote:

Sorry for the delay replying, I've been on vacation and travelling.

> diff --git a/tools/libxl/libxl_types.idl b/tools/libxl/libxl_types.idl
> index a412f9c..6c5d7e0 100644
> --- a/tools/libxl/libxl_types.idl
> +++ b/tools/libxl/libxl_types.idl
> @@ -363,7 +363,7 @@ libxl_domain_build_info = Struct("domain_build_info",[
>                                         ("acpi_s3",          libxl_defbool),
>                                         ("acpi_s4",          libxl_defbool),
>                                         ("nx",               libxl_defbool),
> -                                       ("viridian",         libxl_defbool),
> +                                       ("viridian",         libxl_string_list),

Unfortunately this will break the API. specifically existing  apps which
call libxl_defbool_set on this field will now get a type error.

You need to keep the existing viridian field and add a new one with the
new semantics and a new name (e.g. viridian_features, or a set of new
defbools as I suggested in my previous mail) and define the precedence.
See usbdevice vs. usbdevice_list or the (very new) serial one for
existing examples of this sort of thing.

For your case though you could continue to treat the viridian defbool as
a gate on a bunch of viridian_feature_X defbools, IOW if viridian ==
false the others are ignored, if it is true then the others have the
usual defbool behaviour of defaults and overrides. I think that would
fall out fairly naturally in the setdefault function.

Ian.

  parent reply	other threads:[~2014-08-26 20:28 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-05 13:07 [PATCH v5 0/3] x86/viridian improvements Paul Durrant
2014-08-05 13:07 ` [PATCH v5 1/3] x86/viridian: Re-purpose the HVM parameter to be a feature mask Paul Durrant
2014-08-12 15:25   ` Ian Jackson
2014-08-13 11:09     ` Paul Durrant
2014-08-26 20:24       ` Ian Campbell
2014-08-26 20:28   ` Ian Campbell [this message]
2014-08-27  8:11     ` Paul Durrant
2014-08-05 13:07 ` [PATCH v5 2/3] x86/viridian: Make logging less verbose Paul Durrant
2014-08-05 13:07 ` [PATCH v5 3/3] x86/viridian: Add partition time reference counter MSR support Paul Durrant
2014-08-12 15:27   ` Ian Jackson
2014-08-13 15:27   ` Egger, Christoph
2014-08-27 14:04     ` Paul Durrant
2014-08-12 10:16 ` [PATCH v5 0/3] x86/viridian improvements Paul Durrant
2014-08-12 10:38   ` Jan Beulich
2014-08-12 11:49     ` Paul Durrant
2014-08-12 12:17       ` Jan Beulich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1409084910.28009.33.camel@citrix.com \
    --to=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=jbeulich@suse.com \
    --cc=keir@xen.org \
    --cc=paul.durrant@citrix.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).