[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] public: add RING_NR_UNCONSUMED_*() macros to ring.h
- To: Juergen Gross <jgross@xxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Fri, 26 Nov 2021 11:04:22 +0100
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=zcudEqs7iYh3foiGqUp+NPkmuCZIOsFGT8lRli8M/0I=; b=Vqys0SYbDeRG9DTiZrQ7I8EJmYdWUR4nAN93OBda+ipl5K70jVVXPPEWC6eVaJDpOmIGtLuB3zxLoqp9KdpQeO2wY3PR278a6W1b0QUC0nBpID3BSnqsgqPRXslUUcgl8b6W7THC8W8/jz2VAy8uPPd5l+4co3BscVPVaDL/RuwyeamCO+CuBZxqTHa39shTlQ2pa/LPz8d+S7MRTjx0UzjoOOiSjpHcm+Qlm8kH2Rxit4wovFx4onb9kDEJdXIreaour9mzLPb1Ug1fyKyy+fCXUpyhQmd8DYIXA2p+lScVEGqolPZYKEFEX8k0KKArQAYiZnxulzXLQrcbHpGCOQ==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=FLLtBkyNsCTT3w4IuMGgfgyQNVGN+vMHzQnTSb807Veh5XX7SUPBaVUPfOLcJrSCYjdROSqB7bcoWEEzNM521ya5dcuCVSiySy28Sp8QWTXg0LzOHsZJ0bkr23oHUtSzsF1IObcgT6qYJvgDM4a4NQSyIkQVYQm4VmW5xRN/hEaPSYms4IcWZwFxA+71quLMV2bxL8WiheYI1IKsm+biiv7GS/seAXypJCqSvQQkWbQoszJmmnlv8jTgPrfv3v0WgM9/AxBzwCcwF1CMO6Q9fwjOM6ehchaXeOX2079QZEn2uYtzBi9VXOphltgjh/PppVlueMqt9uleDtZSLeEOZg==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: Roger Pau Monne <roger.pau@xxxxxxxxxx>, Manuel Bouyer <bouyer@xxxxxxxxxxxxxxx>, Simon Kuenzer <simon.kuenzer@xxxxxxxxx>, Paul Durrant <paul@xxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxxx
- Delivery-date: Fri, 26 Nov 2021 10:04:53 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 26.11.2021 10:21, Juergen Gross wrote:
> On 26.11.21 10:17, Jan Beulich wrote:
>> On 26.11.2021 07:55, Juergen Gross wrote:
>>> Today RING_HAS_UNCONSUMED_*() macros are returning the number of
>>> unconsumed requests or responses instead of a boolean as the name of
>>> the macros would imply.
>>>
>>> As this "feature" is already being used, rename the macros to
>>> RING_NR_UNCONSUMED_*() and define the RING_HAS_UNCONSUMED_*() macros
>>> by using the new RING_NR_UNCONSUMED_*() macros. In order to avoid
>>> future misuse let RING_HAS_UNCONSUMED_*() really return a boolean.
>>
>> I don't think we can go this far; consumers of our headers may choose
>> to do so, but anyone taking the headers verbatim would be at risk of
>> getting screwed if they had any instance of abuse in their trees. IOW
>> I think the original-name macros ought to be direct aliases of the
>> new-name ones, and only in Linux'es clone you could then go further.
>
> Fine with me. I'm inclined to add a comment hinting at that possibility
> then.
Indeed, please do.
Jan
|