Skip to content

bitmap: cleanup bitmap_*_region() implementation

Yury Norov lkml 6 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v5 Latest8 patches 2 repliesIn review
  2. v48 patches 5 repliesSuperseded
  3. v38 patches 10 repliesSuperseded
Earlier versions · 3
VersionPostedPatchesRepliesStatus
v2 posting 2/26 patches8 repliesSuperseded
v2 posting 1/20 of 6 patches0 repliesSuperseded
v16 patches4 repliesSuperseded

Patches in v5 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/8bitmap: align __reg_op() wrappers with modern coding stylelib/bitmap.c+5 -70 replies
2/8bitmap: add test for bitmap_*_region() functionslib/test_bitmap.c+24 -00 replies
3/8bitmap: fix opencoded bitmap_allocate_region()lib/bitmap.c+2 -40 replies
4/8bitmap: replace _reg_op(REG_OP_ALLOC) with bitmap_set()lib/bitmap.c+4 -10 replies
5/8bitmap: replace _reg_op(REG_OP_RELEASE) with bitmap_clear()lib/bitmap.c+1 -10 replies
6/8bitmap: replace _reg_op(REG_OP_ISFREE) with find_next_bit()lib/bitmap.c+1 -10 replies
7/8bitmap: drop _reg_op() functionlib/bitmap.c+0 -760 replies
8/8bitmap: move bitmap_*_region() functions to bitmap.hinclude/linux/bitmap.h lib/bitmap.c+60 -660 replies

Reviews trailers per patch

2 of 8 patches have a Reviewed-by or Acked-by.

PatchAndy Shevchenko
1/8R-b
2/8R-b
3/8
4/8
5/8
6/8
7/8
8/8

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v5 thread

Cover letter [PATCH v5 0/8] bitmap: cleanup bitmap_*_region() implementation

bitmap_{allocate,find_free,release}_region() functions are implemented on top of _reg_op() machinery. It duplicates existing generic functionality with no benefits. In fact, generic alternatives may work even better because they optimized for small_const_nbits() case and overall very well optimized for performance and code generation.

This series drops _reg_op() entirely.

v2: https://lore.kernel.org/lkml/[email protected]/T/
v3: https://lore.kernel.org/lkml/[email protected]/T/
v4: https://lore.kernel.org/lkml/[email protected]/T/
v5: - fix bitmap_release_region() implementation;
- address nits for commits comments.

Yury Norov (8):
bitmap: align __reg_op() wrappers with modern coding style
bitmap: add test for bitmap_*_region() functions
bitmap: fix opencoded bitmap_allocate_region()
bitmap: replace _reg_op(REG_OP_ALLOC) with bitmap_set()
bitmap: replace _reg_op(REG_OP_RELEASE) with bitmap_clear()
bitmap: replace _reg_op(REG_OP_ISFREE) with find_next_bit()
bitmap: drop _reg_op() function
bitmap: move bitmap_*_region() functions to bitmap.h

 include/linux/bitmap.h |  63 ++++++++++++++++++-
 lib/bitmap.c           | 140 -----------------------------------------
 lib/test_bitmap.c      |  24 +++++++
 3 files changed, 84 insertions(+), 143 deletions(-)
Signature · 1 line
2.39.2