On Fri, Oct 06, 2023 at 11:33:47AM -0700, Kuppuswamy Sathyanarayanan wrote: > Hi Kirill, > > On 10/5/2023 6:13 AM, Kirill A. Shutemov wrote: > > In order to prepare for the expansion of support for the ACPI MADT > > wakeup method, the relevant code has been moved into a separate file. > > A new configuration option has been introduced to clearly indicate > > dependencies without the use of ifdefs. > > > > There have been no functional changes. > > > > Signed-off-by: Kirill A. Shutemov <kirill.shutemov@xxxxxxxxxxxxxxx> > > --- > > arch/x86/Kconfig | 7 +++ > > arch/x86/include/asm/acpi.h | 5 ++ > > arch/x86/kernel/acpi/Makefile | 11 ++-- > > arch/x86/kernel/acpi/boot.c | 86 +----------------------------- > > arch/x86/kernel/acpi/madt_wakeup.c | 80 +++++++++++++++++++++++++++ > > 5 files changed, 99 insertions(+), 90 deletions(-) > > create mode 100644 arch/x86/kernel/acpi/madt_wakeup.c > > > > diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig > > index 3154dbc49cf5..7368d254d01f 100644 > > --- a/arch/x86/Kconfig > > +++ b/arch/x86/Kconfig > > @@ -1108,6 +1108,13 @@ config X86_LOCAL_APIC > > depends on X86_64 || SMP || X86_32_NON_STANDARD || X86_UP_APIC || PCI_MSI > > select IRQ_DOMAIN_HIERARCHY > > > > +config X86_ACPI_MADT_WAKEUP > > + def_bool y > > + depends on X86_64 > > + depends on ACPI > > + depends on SMP > > + depends on X86_LOCAL_APIC > > + > > config X86_IO_APIC > > def_bool y > > depends on X86_LOCAL_APIC || X86_UP_IOAPIC > > diff --git a/arch/x86/include/asm/acpi.h b/arch/x86/include/asm/acpi.h > > index c8a7fc23f63c..b536b5a6a57b 100644 > > --- a/arch/x86/include/asm/acpi.h > > +++ b/arch/x86/include/asm/acpi.h > > @@ -73,6 +73,11 @@ static inline bool acpi_skip_set_wakeup_address(void) > > > > #define acpi_skip_set_wakeup_address acpi_skip_set_wakeup_address > > > > +union acpi_subtable_headers; > > + > > +int __init acpi_parse_mp_wake(union acpi_subtable_headers *header, > > + const unsigned long end); > > + > > IMO, you don't need to declare acpi_parse_mp_wake() in asm/acpi.h. Since the > only user of this function is in arch/x86/kernel/acpi, you can either create > a header file there or re-use sleep.h. Is it a really a bid deal? I don't see how it fits into sleep.h and introducing one more header file for one declaration seems excessive. > If you want to leave it here, do you want to protect it with > CONFIG_X86_ACPI_MADT_WAKEUP? Declarations are harmless if nobody uses them. Needless ifdeffery hurts eyes :P -- Kiryl Shutsemau / Kirill A. Shutemov _______________________________________________ kexec mailing list kexec@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/kexec