From patchwork Wed Oct 7 04:30:10 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Grant Likely X-Patchwork-Id: 35234 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id 7DE90B7BA7 for ; Wed, 7 Oct 2009 15:36:33 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751492AbZJGEat (ORCPT ); Wed, 7 Oct 2009 00:30:49 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751499AbZJGEat (ORCPT ); Wed, 7 Oct 2009 00:30:49 -0400 Received: from mail-pz0-f177.google.com ([209.85.222.177]:48882 "EHLO mail-pz0-f177.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751492AbZJGEas (ORCPT ); Wed, 7 Oct 2009 00:30:48 -0400 Received: by pzk7 with SMTP id 7so4507094pzk.33 for ; Tue, 06 Oct 2009 21:30:12 -0700 (PDT) Received: by 10.115.24.12 with SMTP id b12mr3922118waj.86.1254889812253; Tue, 06 Oct 2009 21:30:12 -0700 (PDT) Received: from angua (S01060016b61d1226.cg.shawcable.net [68.146.92.145]) by mx.google.com with ESMTPS id 20sm670522pxi.4.2009.10.06.21.30.10 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 06 Oct 2009 21:30:11 -0700 (PDT) Received: from [127.0.1.1] (unknown [IPv6:::1]) by angua (Postfix) with ESMTP id 014A5392; Tue, 6 Oct 2009 22:30:10 -0600 (MDT) From: Grant Likely Subject: [RFC PATCH 01/12] of: Rework linux/of.h and asm/prom.h include ordering To: linuxppc-dev@lists.ozlabs.org, benh@kernel.crashing.org, Stephen Rothwell , davem@davemloft.net, sparclinux@vger.kernel.org, monstr@monstr.eu, microblaze-uclinux@itee.uq.edu.au, devicetree-discuss@lists.ozlabs.org Date: Tue, 06 Oct 2009 22:30:10 -0600 Message-ID: <20091007043002.16890.93443.stgit@angua> In-Reply-To: <20091007041007.16890.62194.stgit@angua> References: <20091007041007.16890.62194.stgit@angua> User-Agent: StGIT/0.14.2 MIME-Version: 1.0 Sender: sparclinux-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: sparclinux@vger.kernel.org In preparation to prune things out of the Sparc, PowerPC and Microblaze asm/prom.h files, change the #include statements to ensure that even if asm/prom.h is included first, linux/of.h gets to determine the order in which files are processed. This patch adds a #include to each of the prom.h files *above* the multi-include protection macros to ensure that linux/of.h can define things before prom.h gets processed. At the end of the merge the cross dependencies between the files should be gone and a sane #include scheme can be restored. Signed-off-by: Grant Likely --- arch/microblaze/include/asm/prom.h | 8 ++------ arch/powerpc/include/asm/prom.h | 7 +------ arch/sparc/include/asm/prom.h | 7 +------ 3 files changed, 4 insertions(+), 18 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe sparclinux" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/arch/microblaze/include/asm/prom.h b/arch/microblaze/include/asm/prom.h index 37e6f30..6636889 100644 --- a/arch/microblaze/include/asm/prom.h +++ b/arch/microblaze/include/asm/prom.h @@ -12,6 +12,8 @@ * 2 of the License, or (at your option) any later version. */ +#include /* linux/of.h gets to determine #include ordering */ + #ifndef _ASM_MICROBLAZE_PROM_H #define _ASM_MICROBLAZE_PROM_H #ifdef __KERNEL__ @@ -305,12 +307,6 @@ extern int of_irq_to_resource(struct device_node *dev, int index, */ extern void __iomem *of_iomap(struct device_node *device, int index); -/* - * NB: This is here while we transition from using asm/prom.h - * to linux/of.h - */ -#include - #endif /* __ASSEMBLY__ */ #endif /* __KERNEL__ */ #endif /* _ASM_MICROBLAZE_PROM_H */ diff --git a/arch/powerpc/include/asm/prom.h b/arch/powerpc/include/asm/prom.h index 6ff0418..b0a84ea 100644 --- a/arch/powerpc/include/asm/prom.h +++ b/arch/powerpc/include/asm/prom.h @@ -1,3 +1,4 @@ +#include /* linux/of.h gets to determine #include ordering */ #ifndef _POWERPC_PROM_H #define _POWERPC_PROM_H #ifdef __KERNEL__ @@ -349,11 +350,5 @@ extern int of_irq_to_resource(struct device_node *dev, int index, */ extern void __iomem *of_iomap(struct device_node *device, int index); -/* - * NB: This is here while we transition from using asm/prom.h - * to linux/of.h - */ -#include - #endif /* __KERNEL__ */ #endif /* _POWERPC_PROM_H */ diff --git a/arch/sparc/include/asm/prom.h b/arch/sparc/include/asm/prom.h index 82a190d..0733170 100644 --- a/arch/sparc/include/asm/prom.h +++ b/arch/sparc/include/asm/prom.h @@ -1,3 +1,4 @@ +#include /* linux/of.h gets to determine #include ordering */ #ifndef _SPARC_PROM_H #define _SPARC_PROM_H #ifdef __KERNEL__ @@ -108,12 +109,6 @@ static inline void irq_dispose_mapping(unsigned int virq) { } -/* - * NB: This is here while we transition from using asm/prom.h - * to linux/of.h - */ -#include - extern struct device_node *of_console_device; extern char *of_console_path; extern char *of_console_options;