All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 00/21] add coccinelle scripts for {bitmap,cpumask,nodes}_empty()
@ 2022-05-10 15:47 Yury Norov
  2022-05-10 15:47   ` [cocci] " Yury Norov
                   ` (21 more replies)
  0 siblings, 22 replies; 52+ messages in thread
From: Yury Norov @ 2022-05-10 15:47 UTC (permalink / raw)
  To: Andy Shevchenko, David Laight, Greg Kroah-Hartman, Joe Perches,
	Julia Lawall, Michał Mirosław, Nicholas Piggin,
	Nicolas Palix, Peter Zijlstra, Rasmus Villemoes, Matti Vaittinen,
	linux-kernel
  Cc: Yury Norov

In this series:
 - introduce bitmap.cocci, cpumask.cocci and nodemask.cocci;
 - add checks for cases where bitmap_weight() may be replaced with one of
   "empty, full, gt, lt, ge, le or eq" versions; and
 - address issued found with those scripts.

On top of next-2022-05-06.

Yury Norov (22):
  introduce bitmap.cocci
  introduce cpumask.cocci
  introduce nodemask.cocci
  ice: use bitmap_empty() in ice_vf_has_no_qs_ena()
  iio: replace bitmap_weight with bitmap_weitght_{eq,le} where
    appropriate
  octeontx2: use bitmap_empty() instead of bitmap_weight()
  risc-v: replace bitmap_weight with bitmap_empty in riscv_fill_hwcap()
  bitops: introduce MANY_BITS() macro
  qed: replace bitmap_weight() with MANY_BITS()
  net/mlx5e: simplify mlx5e_set_fecparam()
  KVM: x86: hyper-v: replace bitmap_weight() with hweight64()
  ia64: cleanup remove_siblinginfo()
  x86: smp: move cpumask_weight() out of for-loop in remove_siblinginfo
  x86: smp: use cpumask_weight_eq() in remove_siblinginfo
  net/mlx5: use cpumask_weight_gt() in irq_pool_request_irq()
  x86/tsc: use cpumask_weight_gt() in loop_timeout()
  sched/core: fix opencoded cpumask_any_but() in
    sched_core_cpu_{starting,deactivate}
  sched/core: remove unneeded cpumask_weight in
    sched_core_cpu_{starting,deactivate}
  sched/core: replace cpumask_weight() with cpumask_weight_eq() where
    appropriate
  sched/topology: replace cpumask_weight() with cpumask_weight_eq where
    appropriate
  cpufreq: use cpumask_weight_gt() in policy_is_shared()
  clockevents: use cpumask_weight_eq() in tick_cleanup_dead_cpu()

 MAINTAINERS                                   |   3 +
 arch/ia64/kernel/smpboot.c                    |   4 -
 arch/riscv/kernel/cpufeature.c                |   7 +-
 arch/x86/kernel/smpboot.c                     |   7 +-
 arch/x86/kernel/tsc_sync.c                    |   2 +-
 arch/x86/kvm/hyperv.c                         |   4 +-
 arch/xtensa/kernel/traps.c                    |   5 +-
 drivers/iio/adc/ad_sigma_delta.c              |   2 +-
 drivers/iio/industrialio-buffer.c             |   2 +-
 drivers/net/ethernet/intel/ice/ice_vf_lib.c   |   4 +-
 .../net/ethernet/marvell/octeontx2/af/cgx.c   |   6 +-
 .../net/ethernet/marvell/octeontx2/af/rpm.c   |   2 +-
 .../ethernet/mellanox/mlx5/core/en_ethtool.c  |   4 +-
 .../mellanox/mlx5/core/irq_affinity.c         |   2 +-
 drivers/net/ethernet/qlogic/qed/qed_dev.c     |   3 +-
 include/linux/bitops.h                        |   3 +
 include/linux/cpufreq.h                       |   2 +-
 include/linux/log2.h                          |   2 +-
 kernel/sched/core.c                           |  47 +++-----
 kernel/sched/topology.c                       |   4 +-
 kernel/time/clockevents.c                     |   2 +-
 scripts/coccinelle/api/bitmap.cocci           | 104 ++++++++++++++++++
 scripts/coccinelle/api/cpumask.cocci          |  51 +++++++++
 scripts/coccinelle/api/nodemask.cocci         |  51 +++++++++
 24 files changed, 256 insertions(+), 67 deletions(-)
 create mode 100644 scripts/coccinelle/api/bitmap.cocci
 create mode 100644 scripts/coccinelle/api/cpumask.cocci
 create mode 100644 scripts/coccinelle/api/nodemask.cocci

-- 
2.32.0


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

end of thread, other threads:[~2022-05-22 17:39 UTC | newest]

Thread overview: 52+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-05-10 15:47 [PATCH 00/21] add coccinelle scripts for {bitmap,cpumask,nodes}_empty() Yury Norov
2022-05-10 15:47 ` [PATCH 01/22] introduce bitmap.cocci Yury Norov
2022-05-10 15:47   ` [cocci] " Yury Norov
2022-05-10 15:47 ` [PATCH 02/22] introduce cpumask.cocci Yury Norov
2022-05-10 15:47   ` [cocci] " Yury Norov
2022-05-10 15:47 ` [PATCH 03/22] introduce nodemask.cocci Yury Norov
2022-05-10 15:47   ` [cocci] " Yury Norov
2022-05-10 15:47 ` [PATCH 04/22] ice: use bitmap_empty() in ice_vf_has_no_qs_ena() Yury Norov
2022-05-10 15:47   ` [Intel-wired-lan] " Yury Norov
2022-05-10 15:47 ` [PATCH 05/22] iio: replace bitmap_weight with bitmap_weitght_{eq,le} where appropriate Yury Norov
2022-05-14 15:53   ` Jonathan Cameron
2022-05-14 16:31     ` Joe Perches
2022-05-15 16:40       ` Jonathan Cameron
2022-05-10 15:47 ` [PATCH 06/22] octeontx2: use bitmap_empty() instead of bitmap_weight() Yury Norov
2022-05-10 21:31   ` Jakub Kicinski
2022-05-10 15:47 ` [PATCH 07/22] risc-v: replace bitmap_weight with bitmap_empty in riscv_fill_hwcap() Yury Norov
2022-05-10 15:47   ` Yury Norov
2022-05-10 16:31   ` Anup Patel
2022-05-10 16:31     ` Anup Patel
2022-05-10 15:47 ` [PATCH 08/22] bitops: introduce MANY_BITS() macro Yury Norov
2022-05-10 16:50   ` Alexei Starovoitov
2022-05-10 17:54     ` David Laight
2022-05-10 19:11       ` Yury Norov
2022-05-11 10:59         ` Rasmus Villemoes
2022-05-10 17:57   ` Max Filippov
2022-05-10 19:16     ` Yury Norov
2022-05-11  4:55       ` Max Filippov
2022-05-10 15:47 ` [PATCH 09/22] qed: replace bitmap_weight() with MANY_BITS() Yury Norov
2022-05-10 15:47 ` [PATCH 10/22] net/mlx5e: simplify mlx5e_set_fecparam() Yury Norov
2022-05-10 15:47 ` [PATCH 11/22] KVM: x86: hyper-v: replace bitmap_weight() with hweight64() Yury Norov
2022-05-16 13:08   ` Vitaly Kuznetsov
2022-05-22 14:53   ` Guenter Roeck
2022-05-22 17:39     ` Yury Norov
2022-05-10 15:47 ` [PATCH 12/22] ia64: cleanup remove_siblinginfo() Yury Norov
2022-05-10 15:47   ` Yury Norov
2022-05-10 22:33   ` Andrew Morton
2022-05-10 22:33     ` Andrew Morton
2022-05-10 15:47 ` [PATCH 13/22] x86: smp: move cpumask_weight() out of for-loop in remove_siblinginfo Yury Norov
2022-05-11  9:47   ` Thomas Gleixner
2022-05-10 15:47 ` [PATCH 14/22] x86: smp: use cpumask_weight_eq() " Yury Norov
2022-05-10 15:47 ` [PATCH 15/22] net/mlx5: use cpumask_weight_gt() in irq_pool_request_irq() Yury Norov
2022-05-10 15:47 ` [PATCH 16/22] x86/tsc: use cpumask_weight_gt() in loop_timeout() Yury Norov
2022-05-10 15:47 ` [PATCH 17/22] sched/core: fix opencoded cpumask_any_but() Yury Norov
2022-05-10 16:37   ` Peter Zijlstra
2022-05-10 17:21     ` Valentin Schneider
2022-05-10 15:47 ` [PATCH 18/22] sched/core: remove unneeded cpumask_weight() in sched_core_cpu_{starting,deactivate} Yury Norov
2022-05-10 15:47 ` [PATCH 19/22] sched/core: replace cpumask_weight() with cpumask_weight_eq() where appropriate Yury Norov
2022-05-10 15:47 ` [PATCH 20/22] sched/topology: " Yury Norov
2022-05-10 15:47 ` [PATCH 21/22] cpufreq: use cpumask_weight_gt() in policy_is_shared() Yury Norov
2022-05-11  3:16   ` Viresh Kumar
2022-05-10 15:47 ` [PATCH 22/22] clockevents: use cpumask_weight_eq() in tick_cleanup_dead_cpu() Yury Norov
2022-05-11  8:18   ` Thomas Gleixner

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.