From patchwork Mon Apr 18 21:14:02 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Daney X-Patchwork-Id: 8875311 Return-Path: X-Original-To: patchwork-linux-acpi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 8202E9F36E for ; Mon, 18 Apr 2016 21:17:37 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 96B2820121 for ; Mon, 18 Apr 2016 21:17:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id A1D1B2011E for ; Mon, 18 Apr 2016 21:17:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752147AbcDRVOe (ORCPT ); Mon, 18 Apr 2016 17:14:34 -0400 Received: from mail-pa0-f51.google.com ([209.85.220.51]:36784 "EHLO mail-pa0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751126AbcDRVOb (ORCPT ); Mon, 18 Apr 2016 17:14:31 -0400 Received: by mail-pa0-f51.google.com with SMTP id er2so53996575pad.3; Mon, 18 Apr 2016 14:14:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=kBS76Wbxgw3xYhhwojJUFLz+y5rHGQFEZWouLLukR7E=; b=CfZzU963ydEzKxGQhVSpBCgV6wmIgzdn4//bQUVgygmkPLV1oPJzf0kKlOnAWgANZ9 WeVCY3jGBoav+x6cSeUZR+NigXv6i01wVuweoUFtCNmNosoQPF9SXja5Zje8scDZ0Wmf w1DNNh0Lgj8glFExUWtQQcRcvIqAUwAGcy9BXCn2OC4JXVvN11AnGwweakcWfeAv61RE fYzdf0DDeWgpyZ+fTt0oRTLCw1PfDV7cTq1P06DF7ujEdWVZpm/lu76fvHmEezAKW8xP 8jwDAmjilDTWdL0swSNVeUwXNlOQcMXdUFCaVvGwfq1rvsJwsAyKzw+vZyowOvxfG+lM oQ3Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=kBS76Wbxgw3xYhhwojJUFLz+y5rHGQFEZWouLLukR7E=; b=GQrnzXfzvEAcgEVLk2A0LSxXkMe4ZLUGave/nqJOe3Nremvps9bLeoooVd4uH6zba7 qtRpHfORC1Fa1tg5ShyS5T0OHaX3lLO5mAWCfcfPBNL82fLqWNFzAbEaDXRP7zfF+hM1 9L6riblVa9jYfjByeaAAzPV4eswtCpEUtGUf129ygkQ9Oh5uTgXQEFL5SYauQ761am90 6fWSMzSIAzQXJBgrnWx5CE3Kng4AzB4Vhj6Fsp1UFIcLl8LR5Tjd2xlVFpX9daqfKy98 /0AfC1laaoCx7305HgdJSI+01Dr9BAKMTsBapD6ECWkn9v26iKx+3UEo35Pt352bGVln 52Hg== X-Gm-Message-State: AOPr4FUoxg9nF6dvnR30G1yrtpDHrYWT9lNf1IWBMNVbYBkU9aUVGhLWQezGDJUnWIYKKw== X-Received: by 10.66.63.98 with SMTP id f2mr53199112pas.123.1461014070884; Mon, 18 Apr 2016 14:14:30 -0700 (PDT) Received: from dl.caveonetworks.com ([64.2.3.194]) by smtp.gmail.com with ESMTPSA id g21sm6213312pfb.7.2016.04.18.14.14.26 (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 18 Apr 2016 14:14:28 -0700 (PDT) Received: from dl.caveonetworks.com (localhost.localdomain [127.0.0.1]) by dl.caveonetworks.com (8.14.5/8.14.5) with ESMTP id u3ILEPuN030853; Mon, 18 Apr 2016 14:14:25 -0700 Received: (from ddaney@localhost) by dl.caveonetworks.com (8.14.5/8.14.5/Submit) id u3ILEPMd030852; Mon, 18 Apr 2016 14:14:25 -0700 From: David Daney To: Will Deacon , linux-arm-kernel@lists.infradead.org, Mark Rutland , Catalin Marinas , Tony Luck , Fenghua Yu , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , x86@kernel.org, "Rafael J. Wysocki" , Len Brown , Rob Herring , Frank Rowand , Grant Likely , Robert Moore , Lv Zheng , Hanjun Guo , Marc Zyngier , linux-ia64@vger.kernel.org, linux-acpi@vger.kernel.org, devel@acpica.org Cc: linux-kernel@vger.kernel.org, Robert Richter , David Daney Subject: [PATCH v4 04/14] acpi, numa: Move acpi_numa_arch_fixup() to ia64 only Date: Mon, 18 Apr 2016 14:14:02 -0700 Message-Id: <1461014052-30788-5-git-send-email-ddaney.cavm@gmail.com> X-Mailer: git-send-email 1.7.11.7 In-Reply-To: <1461014052-30788-1-git-send-email-ddaney.cavm@gmail.com> References: <1461014052-30788-1-git-send-email-ddaney.cavm@gmail.com> Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org X-Spam-Status: No, score=-7.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, T_DKIM_INVALID, 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: Robert Richter Since acpi_numa_arch_fixup() is only used in arch ia64, move it there to make a generic interface easier. This avoids empty function stubs or some complex kconfig options for x86 and arm64. Signed-off-by: Robert Richter Signed-off-by: David Daney --- arch/ia64/include/asm/acpi.h | 3 +++ arch/ia64/kernel/acpi.c | 2 +- arch/ia64/kernel/setup.c | 1 + arch/x86/mm/srat.c | 2 -- drivers/acpi/numa.c | 2 -- include/linux/acpi.h | 1 - 6 files changed, 5 insertions(+), 6 deletions(-) diff --git a/arch/ia64/include/asm/acpi.h b/arch/ia64/include/asm/acpi.h index aa0fdf1..a3d0211 100644 --- a/arch/ia64/include/asm/acpi.h +++ b/arch/ia64/include/asm/acpi.h @@ -140,6 +140,9 @@ static inline void per_cpu_scan_finalize(int min_cpus, int reserve_cpus) } } } + +extern void acpi_numa_fixup(void); + #endif /* CONFIG_ACPI_NUMA */ #endif /*__KERNEL__*/ diff --git a/arch/ia64/kernel/acpi.c b/arch/ia64/kernel/acpi.c index b1698bc..92b7bc9 100644 --- a/arch/ia64/kernel/acpi.c +++ b/arch/ia64/kernel/acpi.c @@ -524,7 +524,7 @@ acpi_numa_memory_affinity_init(struct acpi_srat_mem_affinity *ma) return 0; } -void __init acpi_numa_arch_fixup(void) +void __init acpi_numa_fixup(void) { int i, j, node_from, node_to; diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c index 2029a38..afddb3e 100644 --- a/arch/ia64/kernel/setup.c +++ b/arch/ia64/kernel/setup.c @@ -552,6 +552,7 @@ setup_arch (char **cmdline_p) early_acpi_boot_init(); # ifdef CONFIG_ACPI_NUMA acpi_numa_init(); + acpi_numa_fixup(); # ifdef CONFIG_ACPI_HOTPLUG_CPU prefill_possible_map(); # endif diff --git a/arch/x86/mm/srat.c b/arch/x86/mm/srat.c index b5f8218..90b6ed9 100644 --- a/arch/x86/mm/srat.c +++ b/arch/x86/mm/srat.c @@ -212,8 +212,6 @@ out_err: return -1; } -void __init acpi_numa_arch_fixup(void) {} - int __init x86_acpi_numa_init(void) { int ret; diff --git a/drivers/acpi/numa.c b/drivers/acpi/numa.c index 2de6068..f41f06b 100644 --- a/drivers/acpi/numa.c +++ b/drivers/acpi/numa.c @@ -316,8 +316,6 @@ int __init acpi_numa_init(void) /* SLIT: System Locality Information Table */ acpi_table_parse(ACPI_SIG_SLIT, acpi_parse_slit); - acpi_numa_arch_fixup(); - if (cnt < 0) return cnt; else if (!parsed_numa_memblks) diff --git a/include/linux/acpi.h b/include/linux/acpi.h index 06ed7e5..ab6fd96 100644 --- a/include/linux/acpi.h +++ b/include/linux/acpi.h @@ -244,7 +244,6 @@ void acpi_numa_slit_init (struct acpi_table_slit *slit); void acpi_numa_processor_affinity_init (struct acpi_srat_cpu_affinity *pa); void acpi_numa_x2apic_affinity_init(struct acpi_srat_x2apic_cpu_affinity *pa); int acpi_numa_memory_affinity_init (struct acpi_srat_mem_affinity *ma); -void acpi_numa_arch_fixup(void); #ifndef PHYS_CPUID_INVALID typedef u32 phys_cpuid_t;