Received: by 2002:a05:7412:da14:b0:e2:908c:2ebd with SMTP id fe20csp569852rdb; Fri, 6 Oct 2023 11:34:03 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH6ldQPA80UzHBYNeiOP+/K5zlMd/IlH5tzXSb6zZtBzlkIg1oHnhOlbT3fN/JTCO/XNY3Z X-Received: by 2002:a17:90a:bc48:b0:26b:5461:8dd5 with SMTP id t8-20020a17090abc4800b0026b54618dd5mr8191731pjv.42.1696617243499; Fri, 06 Oct 2023 11:34:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1696617243; cv=none; d=google.com; s=arc-20160816; b=07VgNK33CexK0xWM540IETWRSXMTgc+gdKh9j87Brp9mZPeQ53X/IMvwjF68S/l8qq zzkUTQtHRLRZHH9irP1iOnVwYJt7V4gZGQ9mJ3yvGgkOBP1cdT+CqzZxcXxM4FokU6ML vSt8Iq5+nOl6kO7yPLn1tJPmtwblwlMSw493RXd5nllKZ/8R70YrqDUcR1s0fU1Lr+Kf x1zGS/UAuEif9R76k+TvT2cLCgp/m3Fu58mmsJjs9Yq+gMXukYrDauaS6fCzVWdJXszL a7DpZt1gYBzw3TMS11xcjKdhIT/giA3TqMc1tcUIMJzg8OWvmI39ozaRc1xDfu/zKPj/ bF/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=ebHAUN+QQB6Slfo1MtKN7HxP5Us7tCoTDlOb5T0wNIE=; fh=cMyFVT0sh6ZwVP2rvst5CQqRq6dUn/5tjJx0MsDQfWQ=; b=jGWj9HSCrwin0CAsLdqCphZPRnV8g1sGHy/GGrElV1B1oLrTyW13sgLj2MERB4tAX7 SFtLHIxIsdaLUL3e+AO8UwtIoVluPbuXI9NQC6diVcfdjvflS8yx5k4JPEeZpsqOremG BjAC2N9WoP+xsiXx9QpTXEWza/KKuHekb3LfNKh40ZyA81MeDn0TJDTJSw4mdsYMJd5+ 7PKKKwwmnvoo7KmQIn1CCB7H1ztxZ3wpKytIoLNijXsBm3muCxiCbJP1eyO46IOVE9AV wWZ4F1hlOy+1QZ9FaDURGQ5XZlO3NYJl/tPiHXxaoReCMl/AvnFyccwF893xnkyyYif2 NTKg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=VkvbEjPB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from fry.vger.email (fry.vger.email. [2620:137:e000::3:8]) by mx.google.com with ESMTPS id lr17-20020a17090b4b9100b0026ce877b4cbsi6594889pjb.151.2023.10.06.11.34.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Oct 2023 11:34:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) client-ip=2620:137:e000::3:8; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=VkvbEjPB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::3:8 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by fry.vger.email (Postfix) with ESMTP id D8D1F80698EC; Fri, 6 Oct 2023 11:34:00 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at fry.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232941AbjJFSdt (ORCPT + 99 others); Fri, 6 Oct 2023 14:33:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230415AbjJFSdt (ORCPT ); Fri, 6 Oct 2023 14:33:49 -0400 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.65]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 919D4BE for ; Fri, 6 Oct 2023 11:33:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1696617227; x=1728153227; h=message-id:date:mime-version:subject:to:cc:references: from:in-reply-to:content-transfer-encoding; bh=LLZX7zRwrS6v1TQS+z2JHoWVTzAPsFpDcoMbYNf7c0Y=; b=VkvbEjPBMg6bSpQGAZoAVA6nB1nq7d7YG60nUOIZWxnOzmbs3+NPC3ge XyE9hLkp4BTFY3XJgOoKx/sVKM1O+tgztQLUrqsxE0ihD/qTXkppGCp+h oW4LHbJVmkBg9RDOo6ASCEMjVVXKkUPPI2b3nP4Y4iXQi3FSeEiFjnHn1 zY5oHGacHPZ7jLRFjrUiaFlMwTyqolDmdTQWO7yToB5KBeDVXvAGEdtbW dxc/TpyC6auwOFXYCJUULJ07Y7RYN8OeXeAbcpD0LAkOv27WaLdBPclJQ aHcz48GA1lf1fuTs9AHtTgVtKLFBrK9iveHu3lR5USYqpVA4F4Xitm2X1 w==; X-IronPort-AV: E=McAfee;i="6600,9927,10855"; a="387688600" X-IronPort-AV: E=Sophos;i="6.03,204,1694761200"; d="scan'208";a="387688600" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Oct 2023 11:33:46 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10855"; a="745950981" X-IronPort-AV: E=Sophos;i="6.03,204,1694761200"; d="scan'208";a="745950981" Received: from wangz2-mobl.amr.corp.intel.com (HELO [10.209.88.26]) ([10.209.88.26]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 06 Oct 2023 11:33:46 -0700 Message-ID: <2be8a356-79c8-49a0-ba93-2a92df119af3@linux.intel.com> Date: Fri, 6 Oct 2023 11:33:47 -0700 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 01/13] x86/acpi: Extract ACPI MADT wakeup code into a separate file Content-Language: en-US To: "Kirill A. Shutemov" , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org Cc: "Rafael J. Wysocki" , Peter Zijlstra , Adrian Hunter , Elena Reshetova , Jun Nakajima , Rick Edgecombe , Tom Lendacky , kexec@lists.infradead.org, linux-coco@lists.linux.dev, linux-kernel@vger.kernel.org References: <20231005131402.14611-1-kirill.shutemov@linux.intel.com> <20231005131402.14611-2-kirill.shutemov@linux.intel.com> From: Kuppuswamy Sathyanarayanan In-Reply-To: <20231005131402.14611-2-kirill.shutemov@linux.intel.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=2.8 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, RCVD_IN_SBL_CSS,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on fry.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (fry.vger.email [0.0.0.0]); Fri, 06 Oct 2023 11:34:01 -0700 (PDT) X-Spam-Level: ** 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 > --- > 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. If you want to leave it here, do you want to protect it with CONFIG_X86_ACPI_MADT_WAKEUP? -- Sathyanarayanan Kuppuswamy Linux Kernel Developer