Skip to contentSkip to conversation

vgacon: Handle HAS_IOPORT dependencies

PATCH In review Niklas Schnelle 2 participants 4 messages Apr 5, 2024 – Apr 9, 2024

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover vgacon: Handle HAS_IOPORT dependencies

Hi Greg, Helge,

This is a follow up in my ongoing effort of making inb()/outb() and similar I/O port accessors compile-time optional. Previously I sent this as a treewide series titled "treewide: Remove I/O port accessors for HAS_IOPORT=n" with the latest being its 5th version[0]. With a significant subset of patches merged I've changed over to per-subsystem series. These series are stand alone and should be merged via the relevant tree such that with all subsystems complete we can follow this up with the final patch that will make the I/O port accessors compile-time optional.

The current state of the full series with changes to the remaining subsystems and the aforementioned final patch can be found for your convenience on my git.kernel.org tree in the has_ioport branch[1]. As for compile-time vs runtime see Linus' reply to my first attempt[2].

Thanks,
Niklas

[0] https://lore.kernel.org/all/[email protected]/
[1] https://git.kernel.org/pub/scm/linux/kernel/git/niks/linux.git/log/?h=has_ioport
[2] https://lore.kernel.org/lkml/CAHk-=wg80je=K7madF4e7WrRNp37e3qh6y10Svhdc7O8SZ_-8g@mail.gmail.com/

Niklas Schnelle (1):
vgacon: add HAS_IOPORT dependencies

 drivers/video/console/Kconfig | 1 +
 1 file changed, 1 insertion(+)
Signature · 1 line
2.40.1
#1 lore raw

PATCH 1/1 vgacon: add HAS_IOPORT dependencies

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.

---
Note: This patch does not depend any not-yet-mainline HAS_IOPORT changes and may be merged via subsystem specific trees at your earliest convenience.

 drivers/video/console/Kconfig | 1 +
 1 file changed, 1 insertion(+)
drivers/video/console/Kconfig +1 -0
index bc31db6ef7d2..a053a2de4432 100644
@@ -10,6 +10,7 @@ config VGA_CONSOLE
 	depends on ALPHA || X86 || \
 		(ARM && ARCH_FOOTBRIDGE) || \
 		(MIPS && (MIPS_MALTA || SIBYTE_BCM112X || SIBYTE_SB1250 || SIBYTE_BCM1x80 || SNI_RM))
+	depends on HAS_IOPORT
 	select APERTURE_HELPERS if (DRM || FB || VFIO_PCI_CORE)
 	default y
 	help
Signature · 1 line
2.40.1
#2 lore raw

Re: [PATCH 1/1] vgacon: add HAS_IOPORT dependencies

Quoted 11 lines · 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.

---
Note: This patch does not depend any not-yet-mainline HAS_IOPORT changes and may be merged via subsystem specific trees at your earliest convenience.

I think this patch can just get dropped now, no need to merge it because it's already handled by e9e3300b6e77 ("vgacon:
rework Kconfig dependencies").

Arnd

#3 lore raw

Re: [PATCH 1/1] vgacon: add HAS_IOPORT dependencies

Quoted 13 lines · Arnd Bergmann
Quoted 11 lines · 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.

---
Note: This patch does not depend any not-yet-mainline HAS_IOPORT changes and may be merged via subsystem specific trees at your earliest convenience.

Quoted 5 lines

I think this patch can just get dropped now, no need to merge it because it's already handled by e9e3300b6e77 ("vgacon:
rework Kconfig dependencies").

Arnd

Makes sense then let's drop this patch.

Thanks,
Niklas