[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 1/2] rangeset: add RANGESETF_no_print flag
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Oleksandr Andrushchenko <Oleksandr_Andrushchenko@xxxxxxxx>
- Date: Tue, 23 Nov 2021 07:49:55 +0000
- Accept-language: en-US
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=epam.com; dmarc=pass action=none header.from=epam.com; dkim=pass header.d=epam.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=q46ah8CYGUsvSqYFYPMvxGjTiEPNA4KXxq5xsnZDOVI=; b=PdgDJjpu2MY0ETNh3o0xFCaho7LQqzSNdbhHJIRaCS1WaRjzzHz5XGCeaDpvpQhvmYKjc90h61HU+6NS79uIkbUu7QddK0NhgrrEWwj6nIyjY/c+fYhudyQBIi/idDJZn5n5lxmfrNv/8ndkCo3bnerMBmzuRG/cDBOKrRE9jksNHRRfQUfYaBBJN06d7f1HlLUFBPTt83hZBJvsWmQKpm4F+pbTaajBQ/4D4NTGOEnHJ9mMHSlLUwvLDmjNWET8dBqJJWn1I2ar+sDHENWgoW4diINsfydKkJGMjUaZEm27jZUxIqQKvpVx2HseQPH7wgI+xlhw92dPJp8+A7+SoQ==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RI84PnZq+D03By66BV+EshIRKHtB78YnblBywBa08E1qKrb5QGSCxyT1VRqmSFfy2p8duDJNsLbgLpv5xhIbk2pSnkye/2Z1wL2mwMYz4bKUeg4qyAkBq63w/NS42NtS/c/NaSxsXbW/I+7kVerG91nWWm+FjfnIoZZrZ9RLzi7EU9bJlqeyBdX4dJAHlweVW+jl3cqyjWGf/M2e6LP6hD7qnVuVXvPhQ+DgY8wgB9oTdULUs4aHCadlxztuUq0gRktCF8GRlXPRtBRHEtHw+K9C9Oui1LtVPv6BFE51Ejw7lvK8BVKL4+ux1QpHwvwi2eS0SPZ5GpXd8uYpdgcOOQ==
- Cc: "roger.pau@xxxxxxxxxx" <roger.pau@xxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Oleksandr Andrushchenko <Oleksandr_Andrushchenko@xxxxxxxx>
- Delivery-date: Tue, 23 Nov 2021 07:50:16 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Thread-index: AQHX34NQb/OdxzJcEUqRnDxd7565ZKwQu1AAgAADEAA=
- Thread-topic: [PATCH 1/2] rangeset: add RANGESETF_no_print flag
On 23.11.21 09:38, Jan Beulich wrote:
> On 22.11.2021 10:28, Oleksandr Andrushchenko wrote:
>> --- a/xen/include/xen/rangeset.h
>> +++ b/xen/include/xen/rangeset.h
>> @@ -51,6 +51,9 @@ void rangeset_limit(
>> /* Pretty-print range limits in hexadecimal. */
>> #define _RANGESETF_prettyprint_hex 0
>> #define RANGESETF_prettyprint_hex (1U << _RANGESETF_prettyprint_hex)
>> +/* Do not print entries marked with this flag. */
>> +#define _RANGESETF_no_print 1
> There's no need for this, so I'd like to ask that you add ...
>
>> +#define RANGESETF_no_print (1U << _RANGESETF_no_print)
> ... just this. In due course we should do away with
> _RANGESETF_prettyprint_hex as well (unless you want to do so right
> at this occasion).
Ok, I can remove "#define _RANGESETF_prettyprint_hex 0" as well
and have both flags defined as
/* Pretty-print range limits in hexadecimal. */
#define RANGESETF_prettyprint_hex (1U << 0)
/* Do not print entries marked with this flag. */
#define RANGESETF_no_print (1U << 1)
Or we can use BIT macro here:
/* Pretty-print range limits in hexadecimal. */
#define RANGESETF_prettyprint_hex BIT(0, U)
/* Do not print entries marked with this flag. */
#define RANGESETF_no_print BIT(1, U)
What's your preference here?
>
> Jan
>
Thank you,
Oleksandr
|