lkml.org 
[lkml]   [2022]   [May]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC v2 02/39] ACPI: add dependency on HAS_IOPORT
    On Fri, Apr 29, 2022 at 03:50:00PM +0200, Niklas Schnelle wrote:
    > In a future patch HAS_IOPORT=n will result in inb()/outb() and friends
    > not being declared. As ACPI always uses I/O port access we simply depend
    > on HAS_IOPORT.

    CONFIG_ACPI depends on ARCH_SUPPORTS_ACPI, which is only set by arm64,
    ia64, and x86, all of which support I/O port access. So does this
    actually solve a problem? I wouldn't think you'd be able to build
    ACPI on s390 even without this patch.

    "ACPI always uses I/O port access" is a pretty broad brush, and it
    would be useful to know specifically what the dependencies are.

    Many ACPI hardware accesses use acpi_hw_read()/acpi_hw_write(), which
    use either MMIO or I/O port accesses depending on what the firmware
    told us.

    > Co-developed-by: Arnd Bergmann <arnd@kernel.org>
    > Signed-off-by: Niklas Schnelle <schnelle@linux.ibm.com>
    > ---
    > drivers/acpi/Kconfig | 1 +
    > 1 file changed, 1 insertion(+)
    >
    > diff --git a/drivers/acpi/Kconfig b/drivers/acpi/Kconfig
    > index 1e34f846508f..8ad0d168004c 100644
    > --- a/drivers/acpi/Kconfig
    > +++ b/drivers/acpi/Kconfig
    > @@ -5,6 +5,7 @@
    >
    > config ARCH_SUPPORTS_ACPI
    > bool
    > + depends on HAS_IOPORT
    >
    > menuconfig ACPI
    > bool "ACPI (Advanced Configuration and Power Interface) Support"
    > --
    > 2.32.0
    >

    \
     
     \ /
      Last update: 2022-05-04 20:25    [W:4.063 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site