linux-api.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH RFC 0/4] Introduce 128-bit IO access
@ 2025-11-12  1:58 Chenghai Huang
  2025-11-12  1:58 ` [PATCH RFC 1/4] UAPI: Introduce 128-bit types and byteswap operations Chenghai Huang
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Chenghai Huang @ 2025-11-12  1:58 UTC (permalink / raw)
  To: arnd, catalin.marinas, will, akpm, anshuman.khandual,
	ryan.roberts, andriy.shevchenko, herbert, linux-kernel,
	linux-arch, linux-arm-kernel, linux-crypto, linux-api
  Cc: fanghao11, shenyang39, liulongfang, qianweili

These patches introduce 128-bit IO access functionality. The reason
is that the current HiSilicon cryptographic devices need to
maintain atomic operations when accessing 128-bit MMIO across
physical and virtual functions.

Currently, 128-bit atomic writes have already been implemented in
the device driver, and the driver also depends on a 128-bit atomic
read access interface. Therefore, we have introduced a generic
128-bit IO access interface to replace the implementation of
128-bit read and write IO interfaces using instructions in the
device driver. When the architecture does not support 128-bit
atomic operations, non-atomic 128-bit read and write interfaces can
be used to make the driver functional.

Weili Qian (4):
  UAPI: Introduce 128-bit types and byteswap operations
  asm-generic/io.h: add io{read,write}128 accessors
  io-128-nonatomic: introduce io{read|write}128_{lo_hi|hi_lo}
  arm64/io: Add {__raw_read|__raw_write}128 support

 arch/arm64/include/asm/io.h                  | 21 +++++++++
 include/asm-generic/io.h                     | 48 ++++++++++++++++++++
 include/linux/io-128-nonatomic-hi-lo.h       | 35 ++++++++++++++
 include/linux/io-128-nonatomic-lo-hi.h       | 34 ++++++++++++++
 include/uapi/linux/byteorder/big_endian.h    |  6 +++
 include/uapi/linux/byteorder/little_endian.h |  6 +++
 include/uapi/linux/swab.h                    | 10 ++++
 include/uapi/linux/types.h                   |  3 ++
 8 files changed, 163 insertions(+)
 create mode 100644 include/linux/io-128-nonatomic-hi-lo.h
 create mode 100644 include/linux/io-128-nonatomic-lo-hi.h

-- 
2.33.0


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

end of thread, other threads:[~2025-11-13 14:19 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-12  1:58 [PATCH RFC 0/4] Introduce 128-bit IO access Chenghai Huang
2025-11-12  1:58 ` [PATCH RFC 1/4] UAPI: Introduce 128-bit types and byteswap operations Chenghai Huang
2025-11-12  1:58 ` [PATCH RFC 2/4] asm-generic/io.h: add io{read,write}128 accessors Chenghai Huang
2025-11-12  1:58 ` [PATCH RFC 3/4] io-128-nonatomic: introduce io{read|write}128_{lo_hi|hi_lo} Chenghai Huang
2025-11-12 14:48   ` Ben Dooks
2025-11-13 11:10     ` huangchenghai
2025-11-12  1:58 ` [PATCH RFC 4/4] arm64/io: Add {__raw_read|__raw_write}128 support Chenghai Huang
2025-11-12 12:28   ` Mark Rutland
2025-11-12 14:01     ` David Laight
2025-11-12 14:17       ` Mark Rutland
2025-11-13 14:19     ` huangchenghai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).