diff mbox series

Fixed an incorrect value

Message ID 20211129194450.62467-1-ayankuma@xilinx.com (mailing list archive)
State New, archived
Headers show
Series Fixed an incorrect value | expand

Commit Message

Ayan Kumar Halder Nov. 29, 2021, 7:44 p.m. UTC
GENMASK(30, 21) should be 0x07fe00000

Signed-off-by: Ayan Kumar Halder <ayankuma@xilinx.com>
---

 xen/include/xen/bitops.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Jan Beulich Nov. 30, 2021, 7:18 a.m. UTC | #1
On 29.11.2021 20:44, Ayan Kumar Halder wrote:
> GENMASK(30, 21) should be 0x07fe00000

Please can this have a meaningful title? E.g. "bitops: fix incorrect
value in comment"?

> --- a/xen/include/xen/bitops.h
> +++ b/xen/include/xen/bitops.h
> @@ -5,7 +5,7 @@
>  /*
>   * Create a contiguous bitmask starting at bit position @l and ending at
>   * position @h. For example
> - * GENMASK(30, 21) gives us the 32bit vector 0x01fe00000.
> + * GENMASK(30, 21) gives us the 32bit vector 0x07fe00000.

Once at it I think you also want to
- replace the word "vector",
- drop the odd leading 0: The number would better be 8 digits or
  16 digits, but not 9.

Jan
Ayan Kumar Halder Nov. 30, 2021, 9:37 a.m. UTC | #2
Hi Jan,

Thanks for the review. Just one question.

On 30/11/2021 07:18, Jan Beulich wrote:
> On 29.11.2021 20:44, Ayan Kumar Halder wrote:
>> GENMASK(30, 21) should be 0x07fe00000
> 
> Please can this have a meaningful title? E.g. "bitops: fix incorrect
> value in comment"?
> 
>> --- a/xen/include/xen/bitops.h
>> +++ b/xen/include/xen/bitops.h
>> @@ -5,7 +5,7 @@
>>   /*
>>    * Create a contiguous bitmask starting at bit position @l and ending at
>>    * position @h. For example
>> - * GENMASK(30, 21) gives us the 32bit vector 0x01fe00000.
>> + * GENMASK(30, 21) gives us the 32bit vector 0x07fe00000.
> 
> Once at it I think you also want to
> - replace the word "vector",
Should I replace "vector" with "value" ?

- Ayan

> - drop the odd leading 0: The number would better be 8 digits or
>    16 digits, but not 9.
> 
> Jan
>
Jan Beulich Nov. 30, 2021, 10:31 a.m. UTC | #3
On 30.11.2021 10:37, Ayan Kumar Halder wrote:
> On 30/11/2021 07:18, Jan Beulich wrote:
>> On 29.11.2021 20:44, Ayan Kumar Halder wrote:
>>> GENMASK(30, 21) should be 0x07fe00000
>>
>> Please can this have a meaningful title? E.g. "bitops: fix incorrect
>> value in comment"?
>>
>>> --- a/xen/include/xen/bitops.h
>>> +++ b/xen/include/xen/bitops.h
>>> @@ -5,7 +5,7 @@
>>>   /*
>>>    * Create a contiguous bitmask starting at bit position @l and ending at
>>>    * position @h. For example
>>> - * GENMASK(30, 21) gives us the 32bit vector 0x01fe00000.
>>> + * GENMASK(30, 21) gives us the 32bit vector 0x07fe00000.
>>
>> Once at it I think you also want to
>> - replace the word "vector",
> Should I replace "vector" with "value" ?

Perhaps, yes.

Jan
Ayan Kumar Halder Nov. 30, 2021, 6:14 p.m. UTC | #4
Hi Jan,

On 30/11/2021 10:31, Jan Beulich wrote:
> On 30.11.2021 10:37, Ayan Kumar Halder wrote:
>> On 30/11/2021 07:18, Jan Beulich wrote:
>>> On 29.11.2021 20:44, Ayan Kumar Halder wrote:
>>>> GENMASK(30, 21) should be 0x07fe00000
>>>
>>> Please can this have a meaningful title? E.g. "bitops: fix incorrect
>>> value in comment"?
>>>
>>>> --- a/xen/include/xen/bitops.h
>>>> +++ b/xen/include/xen/bitops.h
>>>> @@ -5,7 +5,7 @@
>>>>    /*
>>>>     * Create a contiguous bitmask starting at bit position @l and ending at
>>>>     * position @h. For example
>>>> - * GENMASK(30, 21) gives us the 32bit vector 0x01fe00000.
>>>> + * GENMASK(30, 21) gives us the 32bit vector 0x07fe00000.
>>>
>>> Once at it I think you also want to
>>> - replace the word "vector",
>> Should I replace "vector" with "value" ?
> 
> Perhaps, yes.
Thanks for the review. I have sent a v2 patch.

- Ayan

> 
> Jan
>
diff mbox series

Patch

diff --git a/xen/include/xen/bitops.h b/xen/include/xen/bitops.h
index a64595f68e..2c8522d218 100644
--- a/xen/include/xen/bitops.h
+++ b/xen/include/xen/bitops.h
@@ -5,7 +5,7 @@ 
 /*
  * Create a contiguous bitmask starting at bit position @l and ending at
  * position @h. For example
- * GENMASK(30, 21) gives us the 32bit vector 0x01fe00000.
+ * GENMASK(30, 21) gives us the 32bit vector 0x07fe00000.
  */
 #define GENMASK(h, l) \
     (((~0UL) << (l)) & (~0UL >> (BITS_PER_LONG - 1 - (h))))