linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/2] include/bitmap.h: updates to docs
@ 2020-03-04 14:09 Wolfram Sang
  2020-03-04 14:09 ` [PATCH 1/2] include/bitmap.h: add missing parameter in docs Wolfram Sang
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Wolfram Sang @ 2020-03-04 14:09 UTC (permalink / raw)
  To: linux-doc; +Cc: linux-renesas-soc, Andrew Morton, linux-kernel, Wolfram Sang

While looking for functions to handle region of bits, I stumbled over
two issues in the documentation part of bitmap.h. These two patches
address them.

My guess is that this could go in via Jon's documentation tree, but I
am CCing Andrew nonetheless.

Based on v5.6-rc1.

Looking forward to comments!

   Wolfram


Wolfram Sang (2):
  include/bitmap.h: add missing parameter in docs
  include/bitmap.h: add new functions to documentation

 include/linux/bitmap.h | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

-- 
2.20.1


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH 1/2] include/bitmap.h: add missing parameter in docs
  2020-03-04 14:09 [PATCH 0/2] include/bitmap.h: updates to docs Wolfram Sang
@ 2020-03-04 14:09 ` Wolfram Sang
  2020-03-04 14:09 ` [PATCH 2/2] include/bitmap.h: add new functions to documentation Wolfram Sang
  2020-03-05 21:29 ` [PATCH 0/2] include/bitmap.h: updates to docs Dennis Zhou
  2 siblings, 0 replies; 8+ messages in thread
From: Wolfram Sang @ 2020-03-04 14:09 UTC (permalink / raw)
  To: linux-doc; +Cc: linux-renesas-soc, Andrew Morton, linux-kernel, Wolfram Sang

bitmap_find_next_zero_area_off() has an additional parameter which was
not specified in the list of functions. Add it.

Fixes: 5e19b013f55a ("lib: bitmap: add alignment offset for bitmap_find_next_zero_area()")
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
 include/linux/bitmap.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/bitmap.h b/include/linux/bitmap.h
index e52ceb1a73d3..804600f7dc35 100644
--- a/include/linux/bitmap.h
+++ b/include/linux/bitmap.h
@@ -50,7 +50,7 @@
  *  bitmap_set(dst, pos, nbits)                 Set specified bit area
  *  bitmap_clear(dst, pos, nbits)               Clear specified bit area
  *  bitmap_find_next_zero_area(buf, len, pos, n, mask)  Find bit free area
- *  bitmap_find_next_zero_area_off(buf, len, pos, n, mask)  as above
+ *  bitmap_find_next_zero_area_off(buf, len, pos, n, mask, mask_off)  as above
  *  bitmap_shift_right(dst, src, n, nbits)      *dst = *src >> n
  *  bitmap_shift_left(dst, src, n, nbits)       *dst = *src << n
  *  bitmap_cut(dst, src, first, n, nbits)       Cut n bits from first, copy rest
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 2/2] include/bitmap.h: add new functions to documentation
  2020-03-04 14:09 [PATCH 0/2] include/bitmap.h: updates to docs Wolfram Sang
  2020-03-04 14:09 ` [PATCH 1/2] include/bitmap.h: add missing parameter in docs Wolfram Sang
@ 2020-03-04 14:09 ` Wolfram Sang
  2020-03-04 20:40   ` Dennis Zhou
  2020-03-05 21:29 ` [PATCH 0/2] include/bitmap.h: updates to docs Dennis Zhou
  2 siblings, 1 reply; 8+ messages in thread
From: Wolfram Sang @ 2020-03-04 14:09 UTC (permalink / raw)
  To: linux-doc
  Cc: linux-renesas-soc, Andrew Morton, linux-kernel, Wolfram Sang,
	Dennis Zhou

I found these functions only by chance although I was looking exactly
for something like them. So, add them to the list of functions to make
them more visible.

Fixes: e837dfde15a4 ("bitmap: genericize percpu bitmap region iterators")
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Cc: Dennis Zhou <dennis@kernel.org>
---
 include/linux/bitmap.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/include/linux/bitmap.h b/include/linux/bitmap.h
index 804600f7dc35..71ba0ffaa22a 100644
--- a/include/linux/bitmap.h
+++ b/include/linux/bitmap.h
@@ -51,6 +51,12 @@
  *  bitmap_clear(dst, pos, nbits)               Clear specified bit area
  *  bitmap_find_next_zero_area(buf, len, pos, n, mask)  Find bit free area
  *  bitmap_find_next_zero_area_off(buf, len, pos, n, mask, mask_off)  as above
+ *  bitmap_next_clear_region(map, &start, &end, nbits)  Find next cleared region
+ *  bitmap_next_set_region(map, &start, &end, nbits)  Find next set region
+ *  bitmap_for_each_clear_region(map, rs, re, start, end)
+ *  						Iterate over all cleared regions
+ *  bitmap_for_each_set_region(map, rs, re, start, end)
+ *  						Iterate over all set regions
  *  bitmap_shift_right(dst, src, n, nbits)      *dst = *src >> n
  *  bitmap_shift_left(dst, src, n, nbits)       *dst = *src << n
  *  bitmap_cut(dst, src, first, n, nbits)       Cut n bits from first, copy rest
-- 
2.20.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH 2/2] include/bitmap.h: add new functions to documentation
  2020-03-04 14:09 ` [PATCH 2/2] include/bitmap.h: add new functions to documentation Wolfram Sang
@ 2020-03-04 20:40   ` Dennis Zhou
  2020-03-05  8:24     ` Wolfram Sang
  0 siblings, 1 reply; 8+ messages in thread
From: Dennis Zhou @ 2020-03-04 20:40 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: linux-doc, linux-renesas-soc, Andrew Morton, linux-kernel, Dennis Zhou

Hi Wolfram,

On Wed, Mar 04, 2020 at 03:09:20PM +0100, Wolfram Sang wrote:
> I found these functions only by chance although I was looking exactly
> for something like them. So, add them to the list of functions to make
> them more visible.
> 
> Fixes: e837dfde15a4 ("bitmap: genericize percpu bitmap region iterators")
> Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> Cc: Dennis Zhou <dennis@kernel.org>
> ---
>  include/linux/bitmap.h | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/include/linux/bitmap.h b/include/linux/bitmap.h
> index 804600f7dc35..71ba0ffaa22a 100644
> --- a/include/linux/bitmap.h
> +++ b/include/linux/bitmap.h
> @@ -51,6 +51,12 @@
>   *  bitmap_clear(dst, pos, nbits)               Clear specified bit area
>   *  bitmap_find_next_zero_area(buf, len, pos, n, mask)  Find bit free area
>   *  bitmap_find_next_zero_area_off(buf, len, pos, n, mask, mask_off)  as above
> + *  bitmap_next_clear_region(map, &start, &end, nbits)  Find next cleared region
> + *  bitmap_next_set_region(map, &start, &end, nbits)  Find next set region
> + *  bitmap_for_each_clear_region(map, rs, re, start, end)
> + *  						Iterate over all cleared regions
> + *  bitmap_for_each_set_region(map, rs, re, start, end)
> + *  						Iterate over all set regions
>   *  bitmap_shift_right(dst, src, n, nbits)      *dst = *src >> n
>   *  bitmap_shift_left(dst, src, n, nbits)       *dst = *src << n
>   *  bitmap_cut(dst, src, first, n, nbits)       Cut n bits from first, copy rest
> -- 
> 2.20.1
> 

Ah thanks. That was a miss not adding the documentation. I can pick
these up unless Andrew would rather run them through his tree. I have a
few other miscellaneous documentation cleanups for percpu I need to run
anyway.

Acked-by: Dennis Zhou <dennis@kernel.org>

Thanks,
Dennis

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 2/2] include/bitmap.h: add new functions to documentation
  2020-03-04 20:40   ` Dennis Zhou
@ 2020-03-05  8:24     ` Wolfram Sang
  2020-03-05 21:33       ` Dennis Zhou
  0 siblings, 1 reply; 8+ messages in thread
From: Wolfram Sang @ 2020-03-05  8:24 UTC (permalink / raw)
  To: Dennis Zhou
  Cc: Wolfram Sang, linux-doc, linux-renesas-soc, Andrew Morton, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 707 bytes --]


> > I found these functions only by chance although I was looking exactly
> > for something like them. So, add them to the list of functions to make
> > them more visible.
> > 
> > Fixes: e837dfde15a4 ("bitmap: genericize percpu bitmap region iterators")
> > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> > Cc: Dennis Zhou <dennis@kernel.org>
> 
> Ah thanks. That was a miss not adding the documentation. I can pick
> these up unless Andrew would rather run them through his tree. I have a
> few other miscellaneous documentation cleanups for percpu I need to run
> anyway.

That sounds like a good fit to me. Will you take both of the patches?

Thanks,

   Wolfram


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 0/2] include/bitmap.h: updates to docs
  2020-03-04 14:09 [PATCH 0/2] include/bitmap.h: updates to docs Wolfram Sang
  2020-03-04 14:09 ` [PATCH 1/2] include/bitmap.h: add missing parameter in docs Wolfram Sang
  2020-03-04 14:09 ` [PATCH 2/2] include/bitmap.h: add new functions to documentation Wolfram Sang
@ 2020-03-05 21:29 ` Dennis Zhou
  2020-03-06  8:17   ` Wolfram Sang
  2 siblings, 1 reply; 8+ messages in thread
From: Dennis Zhou @ 2020-03-05 21:29 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: linux-doc, linux-renesas-soc, Andrew Morton, linux-kernel, Dennis Zhou

On Wed, Mar 04, 2020 at 03:09:18PM +0100, Wolfram Sang wrote:
> While looking for functions to handle region of bits, I stumbled over
> two issues in the documentation part of bitmap.h. These two patches
> address them.
> 
> My guess is that this could go in via Jon's documentation tree, but I
> am CCing Andrew nonetheless.
> 
> Based on v5.6-rc1.
> 
> Looking forward to comments!
> 
>    Wolfram
> 
> 
> Wolfram Sang (2):
>   include/bitmap.h: add missing parameter in docs
>   include/bitmap.h: add new functions to documentation
> 
>  include/linux/bitmap.h | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
> 
> -- 
> 2.20.1
> 
> 

I've applied this to percpu for-5.7.

Thanks,
Dennis

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 2/2] include/bitmap.h: add new functions to documentation
  2020-03-05  8:24     ` Wolfram Sang
@ 2020-03-05 21:33       ` Dennis Zhou
  0 siblings, 0 replies; 8+ messages in thread
From: Dennis Zhou @ 2020-03-05 21:33 UTC (permalink / raw)
  To: Wolfram Sang
  Cc: Dennis Zhou, Wolfram Sang, linux-doc, linux-renesas-soc,
	Andrew Morton, linux-kernel

On Thu, Mar 05, 2020 at 09:24:15AM +0100, Wolfram Sang wrote:
> 
> > > I found these functions only by chance although I was looking exactly
> > > for something like them. So, add them to the list of functions to make
> > > them more visible.
> > > 
> > > Fixes: e837dfde15a4 ("bitmap: genericize percpu bitmap region iterators")
> > > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
> > > Cc: Dennis Zhou <dennis@kernel.org>
> > 
> > Ah thanks. That was a miss not adding the documentation. I can pick
> > these up unless Andrew would rather run them through his tree. I have a
> > few other miscellaneous documentation cleanups for percpu I need to run
> > anyway.
> 
> That sounds like a good fit to me. Will you take both of the patches?
> 
> Thanks,
> 
>    Wolfram
> 

I've picked up both in percpu for-5.7.

Thanks,
Dennis

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 0/2] include/bitmap.h: updates to docs
  2020-03-05 21:29 ` [PATCH 0/2] include/bitmap.h: updates to docs Dennis Zhou
@ 2020-03-06  8:17   ` Wolfram Sang
  0 siblings, 0 replies; 8+ messages in thread
From: Wolfram Sang @ 2020-03-06  8:17 UTC (permalink / raw)
  To: Dennis Zhou
  Cc: Wolfram Sang, linux-doc, linux-renesas-soc, Andrew Morton, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 60 bytes --]


> I've applied this to percpu for-5.7.

Great, thank you!


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2020-03-06  8:17 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-04 14:09 [PATCH 0/2] include/bitmap.h: updates to docs Wolfram Sang
2020-03-04 14:09 ` [PATCH 1/2] include/bitmap.h: add missing parameter in docs Wolfram Sang
2020-03-04 14:09 ` [PATCH 2/2] include/bitmap.h: add new functions to documentation Wolfram Sang
2020-03-04 20:40   ` Dennis Zhou
2020-03-05  8:24     ` Wolfram Sang
2020-03-05 21:33       ` Dennis Zhou
2020-03-05 21:29 ` [PATCH 0/2] include/bitmap.h: updates to docs Dennis Zhou
2020-03-06  8:17   ` Wolfram Sang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).