mbox series

[0/6] RDMA: switch to using CRC32 library functions

Message ID 20250127223840.67280-1-ebiggers@kernel.org (mailing list archive)
Headers show
Series RDMA: switch to using CRC32 library functions | expand

Message

Eric Biggers Jan. 27, 2025, 10:38 p.m. UTC
Starting in 6.14, the crc32() and crc32c() library functions are
directly optimized for each architecture (see
https://git.kernel.org/linus/37b33c68b00089a5), and there is no longer
any need to go through the crypto API.  Therefore uses of the "crc32"
and "crc32c" crypto_shash or crypto_ahash algorithms are being replaced
with straightforward calls to crc32() and crc32c() kernel-wide.  This
patchset does this conversion in drivers/infiniband/.

Compile-tested only.

Eric Biggers (6):
  RDMA/rxe: handle ICRC correctly on big endian systems
  RDMA/rxe: consolidate code for calculating ICRC of packets
  RDMA/rxe: switch to using the crc32 library
  RDMA/irdma: switch to using the crc32c library
  RDMA/siw: fix type of CRC field
  RDMA/siw: switch to using the crc32c library

 drivers/infiniband/hw/irdma/Kconfig   |   1 +
 drivers/infiniband/hw/irdma/main.h    |   1 -
 drivers/infiniband/hw/irdma/osdep.h   |   6 +-
 drivers/infiniband/hw/irdma/puda.c    |  19 ++---
 drivers/infiniband/hw/irdma/puda.h    |   5 +-
 drivers/infiniband/hw/irdma/utils.c   |  47 +----------
 drivers/infiniband/sw/rxe/Kconfig     |   3 +-
 drivers/infiniband/sw/rxe/rxe.c       |   3 -
 drivers/infiniband/sw/rxe/rxe.h       |   1 -
 drivers/infiniband/sw/rxe/rxe_icrc.c  | 114 +++++++-------------------
 drivers/infiniband/sw/rxe/rxe_loc.h   |   1 -
 drivers/infiniband/sw/rxe/rxe_req.c   |   1 -
 drivers/infiniband/sw/rxe/rxe_verbs.c |   4 -
 drivers/infiniband/sw/rxe/rxe_verbs.h |   1 -
 drivers/infiniband/sw/siw/Kconfig     |   4 +-
 drivers/infiniband/sw/siw/iwarp.h     |   2 +-
 drivers/infiniband/sw/siw/siw.h       |  46 ++++++++---
 drivers/infiniband/sw/siw/siw_main.c  |  22 +----
 drivers/infiniband/sw/siw/siw_qp.c    |  56 +++----------
 drivers/infiniband/sw/siw/siw_qp_rx.c |  42 +++++-----
 drivers/infiniband/sw/siw/siw_qp_tx.c |  47 +++++------
 drivers/infiniband/sw/siw/siw_verbs.c |   3 -
 22 files changed, 134 insertions(+), 295 deletions(-)


base-commit: 805ba04cb7ccfc7d72e834ebd796e043142156ba