[PATCH 06/11] io: move PIO_OFFSET to linux/io.h
Arnd Bergmann
arnd at arndb.de
Fri May 9 05:42:05 UTC 2025
On Fri, May 9, 2025, at 05:15, Andrew Ballance wrote:
> From: Fiona Behrens <me at kloenk.dev>
>
> Move the non arch specific PIO size to linux/io.h.
>
> This allows rust to access `PIO_OFFSET`, `PIO_MASK` and
> `PIO_RESERVED`. This is required to implement `IO_COND` in rust.
>
> Signed-off-by: Fiona Behrens <me at kloenk.dev>
> Signed-off-by: Andrew Ballance <andrewjballance at gmail.com>
This puts an implementation detail of the x86 specific
iomap() code (unfortunately named "GENERIC_IOMAP" for historic
reasons) into common code. Please don't do that.
We still have a couple of users of GENERIC_IOMAP outside of
x86, but they all work in subtly different ways, and I've
been thinking about better ways to handle those. Ideally
the nonstandard iomap variants (x86, uml, powerpc/powernv,
m68k/q40) should just implement their own ioread/iowrite
helpers out-of-line like we do on alpha and parisc, while
everyone else just aliases them to readl/writel.
Arnd
More information about the Nouveau
mailing list