All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Campbell <ian.campbell@citrix.com>
To: Jan Beulich <JBeulich@suse.com>,
	Andrew Cooper <andrew.cooper3@citrix.com>
Cc: Keir Fraser <keir@xen.org>, Tim Deegan <tim@xen.org>,
	Ian Jackson <Ian.Jackson@eu.citrix.com>,
	Xen-devel <xen-devel@lists.xen.org>
Subject: Re: [PATCH] public/sysctl: Clarifications to XEN_SYSCTL_PHYSCAP_hvm_directio
Date: Fri, 11 Dec 2015 13:44:26 +0000	[thread overview]
Message-ID: <1449841466.30975.12.camel@citrix.com> (raw)
In-Reply-To: <566AB49302000078000BE95A@prv-mh.provo.novell.com>

On Fri, 2015-12-11 at 03:33 -0700, Jan Beulich wrote:
> > > > On 11.12.15 at 11:20, <andrew.cooper3@citrix.com> wrote:
> > On 11/12/15 07:53, Jan Beulich wrote:
> > > > > > On 10.12.15 at 21:07, <andrew.cooper3@citrix.com> wrote:
> > > > On 01/12/15 13:35, Jan Beulich wrote:
> > > > > > > > On 01.12.15 at 12:37, <andrew.cooper3@citrix.com> wrote:
> > > > > > --- a/xen/include/public/sysctl.h
> > > > > > +++ b/xen/include/public/sysctl.h
> > > > > > @@ -89,7 +89,14 @@
> > > > > > DEFINE_XEN_GUEST_HANDLE(xen_sysctl_tbuf_op_t);
> > > > > >   /* (x86) The platform supports HVM guests. */
> > > > > >  #define _XEN_SYSCTL_PHYSCAP_hvm          0
> > > > > >  #define
> > > > > > XEN_SYSCTL_PHYSCAP_hvm           (1u<<_XEN_SYSCTL_PHYSCAP_hvm)
> > > > > > - /* (x86) The platform supports HVM-guest direct access to I/O
> > > > > > devices. */
> > > > > > + /*
> > > > > > +  * (x86) The platform supports guest direct access to I/O
> > > > > > devices.
> > > > > > +  *
> > > > > > +  * Note that this parameter has been misnamed since its
> > > > > > introduction, and is
> > > > > > +  * now too baked into APIs and ABIs to change.  Despite the
> > > > > > "hvm" in its
> > > > > What do you mean with "too baked into ..."? This is sysctl, which
> > > > > can
> > > > > be changed, and I found just two uses (one in the hypervisor, the
> > > > > other in libxl), so changing the use sites wouldn't seem all that
> > > > > problematic (in the worst case we could also keep to current name
> > > > > behind a __XEN_INTERFACE_VERSION__ conditional).
> > > > It is libxl which is the problem.  Given its stable API,
> > > > libxl_physinfo.cap_hvm_directio can't be changed.
> > > But that's only derived from the sysctl interface, i.e. changing the
> > > name in the public headers won't - unless I'm overlooking something -
> > > have any effect on the libxl interface. It's the libxl implementation
> > > which would then need to explain (for itself) that the name doesn't
> > > reflect the function.
> > 
> > This is all true, but it is better to have it consistent everywhere
> > rather than to change just half of it.
> 
> I disagree (we should eliminate as much confusion as possible), but
> I'm fine to be overruled by other REST maintainers.

I can see both sides of this coin.

If it's just libxl being a pain then we could introduce a new (second)
field and deprecate the old one (while keeping it for compatibility) or
maybe (but probably not) do something with LIBXL_API_VERSION to have a
single field with a dual personality.

We also have the (rather more extreme) of deprecating libxl_get_physinfo
entirely and adding a new more general interface which doesn't encode
hypervisor specifics quite so hardcodedly. I've no idea what such an
interface would look like though, and it would seem like overkill.

Ian.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

      reply	other threads:[~2015-12-11 13:44 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-26 17:02 [PATCH] x86/sysctl: Hide hvm_directio if hvm is not available Andrew Cooper
2015-11-27  8:31 ` Jan Beulich
2015-12-01 11:37   ` [PATCH] public/sysctl: Clarifications to XEN_SYSCTL_PHYSCAP_hvm_directio Andrew Cooper
2015-12-01 13:35     ` Jan Beulich
2015-12-10 20:07       ` Andrew Cooper
2015-12-11  7:53         ` Jan Beulich
2015-12-11 10:20           ` Andrew Cooper
2015-12-11 10:33             ` Jan Beulich
2015-12-11 13:44               ` Ian Campbell [this message]

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=1449841466.30975.12.camel@citrix.com \
    --to=ian.campbell@citrix.com \
    --cc=Ian.Jackson@eu.citrix.com \
    --cc=JBeulich@suse.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=keir@xen.org \
    --cc=tim@xen.org \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.