Re: [PATCH] drivers: char: SONYPI depends on HAS_IOPORT

From: Randy Dunlap
Date: Tue Jun 17 2025 - 14:41:40 EST




On 6/6/25 12:12 AM, Johannes Berg wrote:
> From: Johannes Berg <johannes.berg@xxxxxxxxx>
>
> It already depends on X86_32, but that's also set for ARCH=um.
> Recent changes made UML no longer have IO port access since
> it's not needed, but this driver uses it. Build it only for
> HAS_IOPORT. This is pretty much the same as depending on X86,
> but on the off-chance that HAS_IOPORT will ever be optional
> on x86 HAS_IOPORT is the real prerequisite.
>
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Closes: https://lore.kernel.org/oe-kbuild-all/202506060742.XR3HcxWA-lkp@xxxxxxxxx/
> Signed-off-by: Johannes Berg <johannes.berg@xxxxxxxxx>

Acked-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
Tested-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>

Thanks.

> ---
> drivers/char/Kconfig | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/char/Kconfig b/drivers/char/Kconfig
> index 8fb33c90482f..36295558dc85 100644
> --- a/drivers/char/Kconfig
> +++ b/drivers/char/Kconfig
> @@ -237,7 +237,7 @@ config APPLICOM
>
> config SONYPI
> tristate "Sony Vaio Programmable I/O Control Device support"
> - depends on X86_32 && PCI && INPUT
> + depends on X86_32 && PCI && INPUT && HAS_IOPORT
> depends on ACPI_EC || !ACPI
> help
> This driver enables access to the Sony Programmable I/O Control

--
~Randy