Skip to content

cpumask: repair cpumask_check()

Yury Norov lkml netdev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest7 patches 9 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7cpumask: fix checking valid cpu rangeinclude/linux/cpumask.h+8 -114 replies
2/7net: fix cpu_max_bits_warn() usage in netif_attrmask_next{,_and}include/linux/netdevice.h+4 -62 replies
3/7cpumask: switch for_each_cpu{,_not} to use for_each_bit()include/linux/cpumask.h include/linux/find.h+8 -90 replies
4/7lib/find_bit: add find_next{,_and}_bit_wrapinclude/linux/find.h lib/cpumask.c+49 -90 replies
5/7lib/bitmap: introduce for_each_set_bit_wrap() macroinclude/linux/cpumask.h include/linux/find.h+41 -40 replies
6/7lib/find: optimize for_each() macrosinclude/linux/find.h+25 -310 replies
7/7lib/bitmap: add tests for for_each() loopslib/test_bitmap.c+243 -10 replies

Reviews trailers per patch

1 of 7 patches has a Reviewed-by or Acked-by.

PatchJakub Kicinski
1/7
2/7A-b
3/7
4/7
5/7
6/7
7/7

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

Read the v1 thread

Cover letter [PATCH 0/7] cpumask: repair cpumask_check()

After switching cpumask to use nr_cpu_ids in [1], cpumask_check() started generating many false-positive warnings. There are some more issues with the cpumask_check() that brake it.

This series fixes cpumask_check() mess and addresses most of the false-positive warnings observed on boot of x86_64 and arm64.

[1] https://lore.kernel.org/lkml/[email protected]/T/

Yury Norov (7):
cpumask: fix checking valid cpu range
net: fix cpu_max_bits_warn() usage in netif_attrmask_next{,_and}
cpumask: switch for_each_cpu{,_not} to use for_each_bit() lib/find_bit: add find_next{,_and}_bit_wrap lib/bitmap: introduce for_each_set_bit_wrap() macro lib/find: optimize for_each() macros
lib/bitmap: add tests for for_each() iterators

 include/linux/cpumask.h   |  37 ++----
 include/linux/find.h      | 140 +++++++++++++++++-----
 include/linux/netdevice.h |  10 +-
 lib/cpumask.c             |  12 +-
 lib/test_bitmap.c         | 244 +++++++++++++++++++++++++++++++++++++-
 5 files changed, 375 insertions(+), 68 deletions(-)
Signature · 1 line
2.34.1