Re: [PATCH v6 3/5] drm: handle HAS_IOPORT dependencies

2024-10-07 Thread Lucas De Marchi
On Mon, Oct 07, 2024 at 01:40:21PM +0200, Niklas Schnelle wrote: In a future patch HAS_IOPORT=n will disable inb()/outb() and friends at compile time. We thus need to add HAS_IOPORT as dependency for those drivers using them. In the bochs driver there is optional MMIO support detected at runtime,

[PATCH v6 1/5] hexagon: Don't select GENERIC_IOMAP without HAS_IOPORT support

2024-10-07 Thread Niklas Schnelle
In a future patch HAS_IOPORT=n will disable inb()/outb() and friends at compile time. As hexagon does not support I/O port access it also the GENERIC_IOMAP mechanism of dynamically choosing between I/O port and MMIO access doesn't work so don't select it. Reviewed-by: Brian Cain Co-developed-by:

Re: [PATCH v6 4/5] tty: serial: handle HAS_IOPORT dependencies

2024-10-07 Thread Maciej W. Rozycki
On Mon, 7 Oct 2024, Niklas Schnelle wrote: > diff --git a/drivers/tty/serial/8250/8250_pci.c > b/drivers/tty/serial/8250/8250_pci.c > index > 6709b6a5f3011db38acc58dc7223158fe4fcf72e..6a638feb44e443a1998980dd037748f227ec1bc8 > 100644 > --- a/drivers/tty/serial/8250/8250_pci.c > +++ b/drivers/tt

Re: [PATCH v6 3/5] drm: handle HAS_IOPORT dependencies

2024-10-07 Thread Arnd Bergmann
On Mon, Oct 7, 2024, at 14:39, Lucas De Marchi wrote: > as an example: > $ git grep -lw outb -- drivers/gpu/drm/ > drivers/gpu/drm/gma500/cdv_device.c > drivers/gpu/drm/i915/display/intel_vga.c > drivers/gpu/drm/qxl/qxl_cmd.c > drivers/gpu/drm/qxl/qxl_irq.c > drivers/gpu/drm/tiny/bochs.c > drivers/

Re: [PATCH v6 0/5] treewide: Remove I/O port accessors for HAS_IOPORT=n

2024-10-07 Thread Arnd Bergmann
On Mon, Oct 7, 2024, at 11:40, Niklas Schnelle wrote: > Hi All, > > This is a follow up in my long running effort of making inb()/outb() and > similar I/O port accessors compile-time optional. After initially > sending this as a treewide series with the latest revision at[0] > we switched to per su

Re: [PATCH v6 3/5] drm: handle HAS_IOPORT dependencies

2024-10-07 Thread Lucas De Marchi
On Mon, Oct 07, 2024 at 02:50:11PM +, Arnd Bergmann wrote: On Mon, Oct 7, 2024, at 14:39, Lucas De Marchi wrote: as an example: $ git grep -lw outb -- drivers/gpu/drm/ drivers/gpu/drm/gma500/cdv_device.c drivers/gpu/drm/i915/display/intel_vga.c drivers/gpu/drm/qxl/qxl_cmd.c drivers/gpu/drm/q

[PATCH v6 4/5] tty: serial: handle HAS_IOPORT dependencies

2024-10-07 Thread Niklas Schnelle
In a future patch HAS_IOPORT=n will disable inb()/outb() and friends at compile time. We thus need to add HAS_IOPORT as dependency for those drivers using them unconditionally. Some 8250 serial drivers support MMIO only use, so fence only the parts requiring I/O ports and print an error message if

[PATCH v6 3/5] drm: handle HAS_IOPORT dependencies

2024-10-07 Thread Niklas Schnelle
In a future patch HAS_IOPORT=n will disable inb()/outb() and friends at compile time. We thus need to add HAS_IOPORT as dependency for those drivers using them. In the bochs driver there is optional MMIO support detected at runtime, warn if this isn't taken when HAS_IOPORT is not defined. There is

[PATCH v6 5/5] asm-generic/io.h: Remove I/O port accessors for HAS_IOPORT=n

2024-10-07 Thread Niklas Schnelle
With all subsystems and drivers either declaring their dependence on HAS_IOPORT or fencing I/O port specific code sections we can finally make inb()/outb() and friends compile-time dependent on HAS_IOPORT as suggested by Linus in the linked mail. The main benefit of this is that on platforms such a

[PATCH v6 2/5] Bluetooth: add HAS_IOPORT dependencies

2024-10-07 Thread Niklas Schnelle
In a future patch HAS_IOPORT=n will disable inb()/outb() and friends at compile time. We thus need to add HAS_IOPORT as dependency for those drivers using them. Co-developed-by: Arnd Bergmann Signed-off-by: Arnd Bergmann Signed-off-by: Niklas Schnelle --- drivers/bluetooth/Kconfig | 6 +++---

[PATCH v6 0/5] treewide: Remove I/O port accessors for HAS_IOPORT=n

2024-10-07 Thread Niklas Schnelle
Hi All, This is a follow up in my long running effort of making inb()/outb() and similar I/O port accessors compile-time optional. After initially sending this as a treewide series with the latest revision at[0] we switched to per subsystem series. Now though as we're left with only 5 patches left