public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* (no subject)
@ 2026-05-06 17:52 Yury Norov
  2026-05-06 17:52 ` [PATCH v2 1/5] arch: select HAVE_ARCH_BITREVERSE conditionally on BITREVERSE Yury Norov
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Yury Norov @ 2026-05-06 17:52 UTC (permalink / raw)
  To: Paul Walmsley, Palmer Dabbelt, Albert Ou, Alexandre Ghiti,
	Yury Norov, Rasmus Villemoes, Arnd Bergmann, Eric Biggers,
	Andrew Lunn, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Paolo Abeni, Andrew Morton, Alexei Starovoitov, Daniel Borkmann,
	Jesper Dangaard Brouer, John Fastabend, Stanislav Fomichev,
	Jinjie Ruan, linux-kernel, linux-riscv, linux-arch, netdev, bpf
  Cc: Yury Norov

Subject: [PATCH v2 0/5] lib: rework bitreverse

Cleanup bitreverse-related Kconfig dependency mechanism, and add new
GENERIC_BITREVERSE option to allow architectures to pick the generic
implementation as a fallback for the arch one.

Make RISCV to pick the generic implementation with the absence of ZBKB.

v1: https://lore.kernel.org/all/20260430211351.658193-1-ynorov@nvidia.com/
v2:
 - don't protect headers with the corresponding configs (Arnd, Erik);
 - make HAVE_ARCH_BITREVERSE conditional on BITREVERSE;
 - make GENERIC_BITREVERSE tri-state (sashiko);
 - re-implement GENERIC_BITREVERSE and it's relation to BITREVERSE and
   HAVE_ARCH_BITREVERSE, thus taking over the authorship;
 - RISCV: select GENERIC_BITREVERSE and HAVE_ARCH_BITREVERSE depending
   on BITREVERSE;

Jinjie Ruan (2):
  bitops: Define generic___bitrev8/16/32 for reuse
  arch/riscv: Add bitrev.h file to support rev8 and brev8

Yury Norov (3):
  arch: select HAVE_ARCH_BITREVERSE conditionally on BITREVERSE
  lib/bitrev: Introduce GENERIC_BITREVERSE
  MAINTAINERS: BITOPS: include bitrev.[ch]

 MAINTAINERS                           |  2 ++
 arch/arm/Kconfig                      |  2 +-
 arch/arm64/Kconfig                    |  2 +-
 arch/loongarch/Kconfig                |  2 +-
 arch/mips/Kconfig                     |  2 +-
 arch/riscv/Kconfig                    |  2 ++
 arch/riscv/include/asm/bitrev.h       | 51 +++++++++++++++++++++++++++
 include/asm-generic/bitops/__bitrev.h | 23 ++++++++++++
 include/linux/bitrev.h                | 20 +++--------
 lib/Kconfig                           | 13 +++++++
 lib/Makefile                          |  2 +-
 lib/bitrev.c                          |  3 --
 12 files changed, 100 insertions(+), 24 deletions(-)
 create mode 100644 arch/riscv/include/asm/bitrev.h
 create mode 100644 include/asm-generic/bitops/__bitrev.h

-- 
2.51.0


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

end of thread, other threads:[~2026-05-06 17:53 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-06 17:52 Yury Norov
2026-05-06 17:52 ` [PATCH v2 1/5] arch: select HAVE_ARCH_BITREVERSE conditionally on BITREVERSE Yury Norov
2026-05-06 17:52 ` [PATCH v2 2/5] lib/bitrev: Introduce GENERIC_BITREVERSE Yury Norov
2026-05-06 17:52 ` [PATCH v2 3/5] bitops: Define generic___bitrev8/16/32 for reuse Yury Norov
2026-05-06 17:52 ` [PATCH v2 4/5] arch/riscv: Add bitrev.h file to support rev8 and brev8 Yury Norov
2026-05-06 17:52 ` [PATCH v2 5/5] MAINTAINERS: BITOPS: include bitrev.[ch] Yury Norov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox