From patchwork Sat Jan 30 09:47:29 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shannon Zhao X-Patchwork-Id: 8170481 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id 69F84BEEE5 for ; Sat, 30 Jan 2016 09:51:57 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9865B203A1 for ; Sat, 30 Jan 2016 09:51:56 +0000 (UTC) Received: from lists.xen.org (lists.xenproject.org [50.57.142.19]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id BD6842039E for ; Sat, 30 Jan 2016 09:51:55 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aPS9V-0005Bm-Dq; Sat, 30 Jan 2016 09:49:09 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aPS9T-0005BW-RG for xen-devel@lists.xen.org; Sat, 30 Jan 2016 09:49:07 +0000 Received: from [85.158.139.211] by server-1.bemta-5.messagelabs.com id F5/CB-15353-3178CA65; Sat, 30 Jan 2016 09:49:07 +0000 X-Env-Sender: zhaoshenglong@huawei.com X-Msg-Ref: server-4.tower-206.messagelabs.com!1454147342!19191028!1 X-Originating-IP: [119.145.14.66] X-SpamReason: No, hits=0.0 required=7.0 tests=sa_preprocessor: VHJ1c3RlZCBJUDogMTE5LjE0NS4xNC42NiA9PiA4NTI3\n X-StarScan-Received: X-StarScan-Version: 7.35.1; banners=-,-,- X-VirusChecked: Checked Received: (qmail 32736 invoked from network); 30 Jan 2016 09:49:05 -0000 Received: from szxga03-in.huawei.com (HELO szxga03-in.huawei.com) (119.145.14.66) by server-4.tower-206.messagelabs.com with SMTP; 30 Jan 2016 09:49:05 -0000 Received: from 172.24.1.50 (EHLO szxeml422-hub.china.huawei.com) ([172.24.1.50]) by szxrg03-dlp.huawei.com (MOS 4.4.3-GA FastPath queued) with ESMTP id BVL85778; Sat, 30 Jan 2016 17:48:12 +0800 (CST) Received: from HGHY1Z002260041.china.huawei.com (10.177.16.142) by szxeml422-hub.china.huawei.com (10.82.67.152) with Microsoft SMTP Server id 14.3.235.1; Sat, 30 Jan 2016 17:48:03 +0800 From: Shannon Zhao To: Date: Sat, 30 Jan 2016 17:47:29 +0800 Message-ID: <1454147250-7704-3-git-send-email-zhaoshenglong@huawei.com> X-Mailer: git-send-email 1.9.0.msysgit.0 In-Reply-To: <1454147250-7704-1-git-send-email-zhaoshenglong@huawei.com> References: <1454147250-7704-1-git-send-email-zhaoshenglong@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.177.16.142] X-CFilter-Loop: Reflected X-Mirapoint-Virus-RAPID-Raw: score=unknown(0), refid=str=0001.0A020201.56AC86DC.00AE, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0, ip=0.0.0.0, so=2013-05-26 15:14:31, dmn=2013-03-21 17:37:32 X-Mirapoint-Loop-Id: 63a9ff25d83ca2fcbeecd562dab40bb1 Cc: shannon.zhao@linaro.org, jbeulich@suse.com, peter.huangpeng@huawei.com Subject: [Xen-devel] [PATCH v6 2/3] ACPI: add config for BIOS table scan X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Graeme Gregory With the addition of ARM64 that does not have a traditional BIOS to scan, add a config option which is selected on x86 (ia64 doesn't need it either, it is EFI/UEFI based system) to do the traditional BIOS scanning for tables. Signed-off-by: Graeme Gregory Signed-off-by: Hanjun Guo Signed-off-by: Rafael J. Wysocki [Linux commit 8a1664be0b922dd6afd60eca96a992ef5ec22c40] [Include in osl.c so that it could use IS_ENABLED] Signed-off-by: Shannon Zhao Reviewed-by: Doug Goldstein Reviewed-by: Stefano Stabellini --- xen/arch/x86/Kconfig | 1 + xen/drivers/acpi/Kconfig | 3 +++ xen/drivers/acpi/osl.c | 5 ++++- 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/xen/arch/x86/Kconfig b/xen/arch/x86/Kconfig index 7d2ed96..9fdd3b1 100644 --- a/xen/arch/x86/Kconfig +++ b/xen/arch/x86/Kconfig @@ -3,6 +3,7 @@ config X86_64 config X86 def_bool y + select ACPI_LEGACY_TABLES_LOOKUP select COMPAT select HAS_ACPI select HAS_CPUFREQ diff --git a/xen/drivers/acpi/Kconfig b/xen/drivers/acpi/Kconfig index 11ab5e4..82d73ca 100644 --- a/xen/drivers/acpi/Kconfig +++ b/xen/drivers/acpi/Kconfig @@ -2,3 +2,6 @@ # Select HAS_ACPI if ACPI is supported config HAS_ACPI bool + +config ACPI_LEGACY_TABLES_LOOKUP + bool diff --git a/xen/drivers/acpi/osl.c b/xen/drivers/acpi/osl.c index ce15470..2f1d723 100644 --- a/xen/drivers/acpi/osl.c +++ b/xen/drivers/acpi/osl.c @@ -38,6 +38,7 @@ #include #include #include +#include #define _COMPONENT ACPI_OS_SERVICES ACPI_MODULE_NAME("osl") @@ -75,12 +76,14 @@ acpi_physical_address __init acpi_os_get_root_pointer(void) "System description tables not found\n"); return 0; } - } else { + } else if (IS_ENABLED(CONFIG_ACPI_LEGACY_TABLES_LOOKUP)) { acpi_physical_address pa = 0; acpi_find_root_pointer(&pa); return pa; } + + return 0; } void __iomem *