[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH for-4.15 v2] xen/dmop: Strip __XEN_TOOLS__ header guard from public API
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
- Date: Thu, 11 Mar 2021 13:43:05 +0000
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=CsIkHXPoOGSxp7/5w/kygfKmQ1VAFN1rV9r/PpKO+Ts=; b=jO4g79V+qSzZewqodRyFK9YTcMx555AU48O2Y/96T3c5hDFxnXHTJYirYTWUItOc2ga1A9Cd9SwWUfhdwP9/qlE6l44DtKETf7hDAgNGOioCsJP0L8RQGHUTXTHXMPBBv8Jqwrng6ZEMn5ta9WTgrEv3sKC/5E4YJiHtdxC0uLda/1HIiDz4JY1uME+cfW2BD9ieHEh6G1Fb0waqcNO7yQgkRmgDB4WAbZY+Q6W5JYPFfPFmNyxR6/6peZW9QI30DXX/7PWDbTe4LqFjzewZ4Qr+9Mp+pkkKlhY8LUI6MiOyeKph/+3dthcrM+gIUowke1p7HwbYjyoGBJ/S0/9n2g==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EiBlT+P2omx2KzxpyHvl2NYDY7MlP+cIXCKvhAK0UxRvEI4KI40B3eJVvAEiV7hou8GL+kGri8Dp2zaUbzSB2lXFjVyh5RgiU6beOYUL90VIbGX7SMuoWqVhdmb9kdMq2d+NGy1cThm5bgVUmIstkDrW78NO6NbyKE8bjXcIZlsQdTo5Ev7fjtg33NdOF89FWREmffhmZeCcQh7p8C6czL7V61KY2SWz8TVQk7dhPH+/ChhUuDPjo8c2TWeB6lCBPJnP3mZrQ28eWYmyQ+kMytbSDv/47Un0OeIIhCs7QAgU0P0lwfua0lEfowUDiKKli0gOSSLc71ihPlpxqE9+HQ==
- Authentication-results: esa3.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
- Cc: Roger Pau Monné <roger.pau@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Juergen Gross <jgross@xxxxxxxx>, Paul Durrant <paul@xxxxxxx>
- Delivery-date: Thu, 11 Mar 2021 13:43:45 +0000
- Ironport-hdrordr: A9a23:JySPvKF4m8ickNv6pLqEcseALOonbusQ8zAX/mp2TgFYddHdqt unm+4V2QSxpDEaXnwhnt7oAtjjfVr385lp7Y4NeYqzRQWOghrKEKhOz6vHhwfhFSr36/JH2c 5bGJRWJdXsATFB7PrSzxK/F78br+Wv1ICNqaPgw2x2TQdsApsN0y5cBhyAGkN7AClqbKBJca a03cZMqzq+dXl/VK3SbBQ4dtLerN7Gno+OW347LiMggTPhsRqYrJjgExaZ2R8aeyhVwagr9F XElwCR3NTGj82G
- Ironport-sdr: TNyQV1SFqRtu6AZxxmdfAwKcyaF+OX2pENIvRJwwViuQMIHBSBvLttCdfrF0aFdCxzbkWwa8to E3ksIDMbhayIGCOPcEWb5sjt4Bg2v33vHxl1AlWUW3O6Fprfq68mE9VnZ9hf0zx2Ae1GmgvNRm I6wv5crph4G/xc9i9fLx6wCpFTAY0BXQZd+0lSZedtcyKdqjrPjqq6p0Ae1ut0U43FIMsbsh1d 2kPnyd9ozxeyyaXsG/qm6ePj5TWyA1gHXb/i8j+SVjGFBpNC6kQ/2Nkvx6JIopBv38aCyp6E73 FNk=
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 11/03/2021 13:28, Jan Beulich wrote:
> On 11.03.2021 14:00, Andrew Cooper wrote:
>> However, having laid things out in this way today, it occurs to me that
>> we should consider further cleanup as well.
>>
>> I do agree that code wanting to use the libxendevicemodel.h API almost
>> certainly don't want/need the dmop ABI. (i.e. an individual consumer
>> will want one, or the other, but almost certainly not both together).
>>
>> Should libxendevicemodel.h really be including dm_op.h?
> I was indeed wondering.
>
>> AFAICT, it is
>> only the ioserverid_t typedef which is API shared between the two
>> contexts, and we can trivially typedef that locally.
> Hmm, a local typedef isn't nice - there should be one central point.
> Granted there's no risk for this to change in anywhere halfway
> foreseeable future, but still. Also neither C89 nor C99 allow a
> typedef to be repeated - in those versions we'd then rely on an
> extension.
I wonder if we're depending on that extension elsewhere. As far as the
stable libraries go, we are dependent on a Linux or BSD environment
currently.
Alternatively we can drop the typedef and use uint16_t instead without
breaking things in practice. (As long as we make the change in 4.15 and
we lose the wiggle room afforded us by the entire interface being behind
__XEN_TOOLS__ previously).
Thoughts? I can't think of any ifdefary which would help, and swapping
to uint16_t would reduce the use of an improperly namespaced identifier.
~Andrew
|