Devicetree
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Grant Likely <grant.likely@secretlab.ca>
Cc: monstr@monstr.eu, devicetree-discuss@lists.ozlabs.org,
	microblaze-uclinux@itee.uq.edu.au, sparclinux@vger.kernel.org,
	linuxppc-dev@lists.ozlabs.org, davem@davemloft.net
Subject: [PATCH 2/2] of: move struct property to asm/of.h
Date: Thu, 15 Oct 2009 12:02:49 +1100	[thread overview]
Message-ID: <20091015120249.cf84d941.sfr@canb.auug.org.au> (raw)
In-Reply-To: <20091015120144.73ef384c.sfr@canb.auug.org.au>

Also find all users of struct property and make sure that they include
linux/of.h.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
---
 arch/powerpc/include/asm/of.h                |    7 +++++++
 arch/powerpc/include/asm/prom.h              |    7 +------
 arch/powerpc/kernel/machine_kexec_64.c       |    1 +
 arch/powerpc/kernel/prom.c                   |    1 +
 arch/powerpc/kernel/prom_parse.c             |    2 ++
 arch/powerpc/platforms/maple/pci.c           |    1 +
 arch/powerpc/platforms/powermac/pci.c        |    1 +
 arch/powerpc/platforms/powermac/pfunc_core.c |    1 +
 arch/powerpc/platforms/pseries/reconfig.c    |    1 +
 arch/powerpc/sysdev/qe_lib/qe.c              |    2 ++
 arch/sparc/include/asm/of.h                  |    9 +++++++++
 arch/sparc/include/asm/prom.h                |    9 +--------
 arch/sparc/kernel/pci_psycho.c               |    1 +
 arch/sparc/kernel/pci_schizo.c               |    1 +
 arch/sparc/kernel/pci_sun4v.c                |    1 +
 arch/sparc/kernel/prom_32.c                  |    1 +
 arch/sparc/kernel/prom_64.c                  |    1 +
 drivers/macintosh/smu.c                      |    1 +
 drivers/sbus/char/openprom.c                 |    2 ++
 fs/openpromfs/inode.c                        |    1 +
 fs/proc/proc_devtree.c                       |    2 ++
 21 files changed, 39 insertions(+), 14 deletions(-)

diff --git a/arch/powerpc/include/asm/of.h b/arch/powerpc/include/asm/of.h
index 1c1089a..383f48d 100644
--- a/arch/powerpc/include/asm/of.h
+++ b/arch/powerpc/include/asm/of.h
@@ -20,4 +20,11 @@
 #define of_prop_cmp(s1, s2)		strcmp((s1), (s2))
 #define of_node_cmp(s1, s2)		strcasecmp((s1), (s2))
 
+struct property {
+	char		*name;
+	int		length;
+	void		*value;
+	struct property *next;
+};
+
 #endif /* _POWERPC_OF_H */
diff --git a/arch/powerpc/include/asm/prom.h b/arch/powerpc/include/asm/prom.h
index 07aef9f..97b24c9 100644
--- a/arch/powerpc/include/asm/prom.h
+++ b/arch/powerpc/include/asm/prom.h
@@ -68,12 +68,7 @@ struct boot_param_header
 typedef u32 phandle;
 typedef u32 ihandle;
 
-struct property {
-	char	*name;
-	int	length;
-	void	*value;
-	struct property *next;
-};
+struct property;
 
 struct device_node {
 	const char *name;
diff --git a/arch/powerpc/kernel/machine_kexec_64.c b/arch/powerpc/kernel/machine_kexec_64.c
index 040bd1d..8ff5e00 100644
--- a/arch/powerpc/kernel/machine_kexec_64.c
+++ b/arch/powerpc/kernel/machine_kexec_64.c
@@ -15,6 +15,7 @@
 #include <linux/thread_info.h>
 #include <linux/init_task.h>
 #include <linux/errno.h>
+#include <linux/of.h>
 
 #include <asm/page.h>
 #include <asm/current.h>
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index d4405b9..c7c2655 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -32,6 +32,7 @@
 #include <linux/debugfs.h>
 #include <linux/irq.h>
 #include <linux/lmb.h>
+#include <linux/of.h>
 
 #include <asm/prom.h>
 #include <asm/rtas.h>
diff --git a/arch/powerpc/kernel/prom_parse.c b/arch/powerpc/kernel/prom_parse.c
index 8362620..07698d4 100644
--- a/arch/powerpc/kernel/prom_parse.c
+++ b/arch/powerpc/kernel/prom_parse.c
@@ -6,6 +6,8 @@
 #include <linux/module.h>
 #include <linux/ioport.h>
 #include <linux/etherdevice.h>
+#include <linux/of.h>
+
 #include <asm/prom.h>
 #include <asm/pci-bridge.h>
 
diff --git a/arch/powerpc/platforms/maple/pci.c b/arch/powerpc/platforms/maple/pci.c
index 04296ff..599c192 100644
--- a/arch/powerpc/platforms/maple/pci.c
+++ b/arch/powerpc/platforms/maple/pci.c
@@ -17,6 +17,7 @@
 #include <linux/init.h>
 #include <linux/bootmem.h>
 #include <linux/irq.h>
+#include <linux/of.h>
 
 #include <asm/sections.h>
 #include <asm/io.h>
diff --git a/arch/powerpc/platforms/powermac/pci.c b/arch/powerpc/platforms/powermac/pci.c
index e81403b..ac0ab8d 100644
--- a/arch/powerpc/platforms/powermac/pci.c
+++ b/arch/powerpc/platforms/powermac/pci.c
@@ -17,6 +17,7 @@
 #include <linux/init.h>
 #include <linux/bootmem.h>
 #include <linux/irq.h>
+#include <linux/of.h>
 
 #include <asm/sections.h>
 #include <asm/io.h>
diff --git a/arch/powerpc/platforms/powermac/pfunc_core.c b/arch/powerpc/platforms/powermac/pfunc_core.c
index 96d5ce5..2eb9cde 100644
--- a/arch/powerpc/platforms/powermac/pfunc_core.c
+++ b/arch/powerpc/platforms/powermac/pfunc_core.c
@@ -11,6 +11,7 @@
 #include <linux/spinlock.h>
 #include <linux/module.h>
 #include <linux/mutex.h>
+#include <linux/of.h>
 
 #include <asm/prom.h>
 #include <asm/pmac_pfunc.h>
diff --git a/arch/powerpc/platforms/pseries/reconfig.c b/arch/powerpc/platforms/pseries/reconfig.c
index 2e2bbe1..5d089d7 100644
--- a/arch/powerpc/platforms/pseries/reconfig.c
+++ b/arch/powerpc/platforms/pseries/reconfig.c
@@ -15,6 +15,7 @@
 #include <linux/kref.h>
 #include <linux/notifier.h>
 #include <linux/proc_fs.h>
+#include <linux/of.h>
 
 #include <asm/prom.h>
 #include <asm/machdep.h>
diff --git a/arch/powerpc/sysdev/qe_lib/qe.c b/arch/powerpc/sysdev/qe_lib/qe.c
index 464271b..8e690ca 100644
--- a/arch/powerpc/sysdev/qe_lib/qe.c
+++ b/arch/powerpc/sysdev/qe_lib/qe.c
@@ -27,6 +27,8 @@
 #include <linux/delay.h>
 #include <linux/ioport.h>
 #include <linux/crc32.h>
+#include <linux/of.h>
+
 #include <asm/irq.h>
 #include <asm/page.h>
 #include <asm/pgtable.h>
diff --git a/arch/sparc/include/asm/of.h b/arch/sparc/include/asm/of.h
index 57ab8f9..7aeb0c2 100644
--- a/arch/sparc/include/asm/of.h
+++ b/arch/sparc/include/asm/of.h
@@ -21,4 +21,13 @@
 #define of_prop_cmp(s1, s2)		strcasecmp((s1), (s2))
 #define of_node_cmp(s1, s2)		strcmp((s1), (s2))
 
+struct property {
+	char		*name;
+	int		length;
+	void		*value;
+	struct property *next;
+	unsigned long	 _flags;
+	unsigned int	 unique_id;
+};
+
 #endif /* _SPARC_OF_H */
diff --git a/arch/sparc/include/asm/prom.h b/arch/sparc/include/asm/prom.h
index 4b6ec43..03266c2 100644
--- a/arch/sparc/include/asm/prom.h
+++ b/arch/sparc/include/asm/prom.h
@@ -24,14 +24,7 @@
 typedef u32 phandle;
 typedef u32 ihandle;
 
-struct property {
-	char	*name;
-	int	length;
-	void	*value;
-	struct property *next;
-	unsigned long _flags;
-	unsigned int unique_id;
-};
+struct property;
 
 struct of_irq_controller;
 struct device_node {
diff --git a/arch/sparc/kernel/pci_psycho.c b/arch/sparc/kernel/pci_psycho.c
index 142b9d6..d9c8cde 100644
--- a/arch/sparc/kernel/pci_psycho.c
+++ b/arch/sparc/kernel/pci_psycho.c
@@ -11,6 +11,7 @@
 #include <linux/init.h>
 #include <linux/slab.h>
 #include <linux/interrupt.h>
+#include <linux/of.h>
 #include <linux/of_device.h>
 
 #include <asm/iommu.h>
diff --git a/arch/sparc/kernel/pci_schizo.c b/arch/sparc/kernel/pci_schizo.c
index 2b5cdde..c923817 100644
--- a/arch/sparc/kernel/pci_schizo.c
+++ b/arch/sparc/kernel/pci_schizo.c
@@ -9,6 +9,7 @@
 #include <linux/init.h>
 #include <linux/slab.h>
 #include <linux/interrupt.h>
+#include <linux/of.h>
 #include <linux/of_device.h>
 
 #include <asm/iommu.h>
diff --git a/arch/sparc/kernel/pci_sun4v.c b/arch/sparc/kernel/pci_sun4v.c
index 23c33ff..322dfe0 100644
--- a/arch/sparc/kernel/pci_sun4v.c
+++ b/arch/sparc/kernel/pci_sun4v.c
@@ -13,6 +13,7 @@
 #include <linux/irq.h>
 #include <linux/msi.h>
 #include <linux/log2.h>
+#include <linux/of.h>
 #include <linux/of_device.h>
 
 #include <asm/iommu.h>
diff --git a/arch/sparc/kernel/prom_32.c b/arch/sparc/kernel/prom_32.c
index 0a37e8c..61eafe0 100644
--- a/arch/sparc/kernel/prom_32.c
+++ b/arch/sparc/kernel/prom_32.c
@@ -21,6 +21,7 @@
 #include <linux/mm.h>
 #include <linux/bootmem.h>
 #include <linux/module.h>
+#include <linux/of.h>
 
 #include <asm/prom.h>
 #include <asm/oplib.h>
diff --git a/arch/sparc/kernel/prom_64.c b/arch/sparc/kernel/prom_64.c
index fb06ac2..f05ebdc 100644
--- a/arch/sparc/kernel/prom_64.c
+++ b/arch/sparc/kernel/prom_64.c
@@ -21,6 +21,7 @@
 #include <linux/mm.h>
 #include <linux/module.h>
 #include <linux/lmb.h>
+#include <linux/of.h>
 #include <linux/of_device.h>
 
 #include <asm/prom.h>
diff --git a/drivers/macintosh/smu.c b/drivers/macintosh/smu.c
index 96faa79..743e44a 100644
--- a/drivers/macintosh/smu.c
+++ b/drivers/macintosh/smu.c
@@ -36,6 +36,7 @@
 #include <linux/sysdev.h>
 #include <linux/poll.h>
 #include <linux/mutex.h>
+#include <linux/of.h>
 #include <linux/of_device.h>
 #include <linux/of_platform.h>
 
diff --git a/drivers/sbus/char/openprom.c b/drivers/sbus/char/openprom.c
index 75ac19b..c67a9ab 100644
--- a/drivers/sbus/char/openprom.c
+++ b/drivers/sbus/char/openprom.c
@@ -38,6 +38,8 @@
 #include <linux/miscdevice.h>
 #include <linux/init.h>
 #include <linux/fs.h>
+#include <linux/of.h>
+
 #include <asm/oplib.h>
 #include <asm/prom.h>
 #include <asm/system.h>
diff --git a/fs/openpromfs/inode.c b/fs/openpromfs/inode.c
index ffcd04f..b308cdf 100644
--- a/fs/openpromfs/inode.c
+++ b/fs/openpromfs/inode.c
@@ -12,6 +12,7 @@
 #include <linux/slab.h>
 #include <linux/seq_file.h>
 #include <linux/magic.h>
+#include <linux/of.h>
 
 #include <asm/openprom.h>
 #include <asm/oplib.h>
diff --git a/fs/proc/proc_devtree.c b/fs/proc/proc_devtree.c
index 7ba79a5..42121fc 100644
--- a/fs/proc/proc_devtree.c
+++ b/fs/proc/proc_devtree.c
@@ -9,6 +9,8 @@
 #include <linux/proc_fs.h>
 #include <linux/stat.h>
 #include <linux/string.h>
+#include <linux/of.h>
+
 #include <asm/prom.h>
 #include <asm/uaccess.h>
 #include "internal.h"
-- 
1.6.4.3

-- 
Cheers,
Stephen Rothwell                    sfr@canb.auug.org.au
http://www.canb.auug.org.au/~sfr/

  reply	other threads:[~2009-10-15  1:02 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20091007041007.16890.62194.stgit@angua>
2009-10-07  4:30 ` [RFC PATCH 01/12] of: Rework linux/of.h and asm/prom.h include ordering Grant Likely
2009-10-07  4:30 ` [RFC PATCH 02/12] of: merge phandle, ihandle and struct property Grant Likely
2009-10-07  4:30 ` [RFC PATCH 03/12] of: merge struct device_node Grant Likely
2009-10-07  4:30 ` [RFC PATCH 04/12] of: Move OF_IS_DYNAMIC and OF_MARK_DYNAMIC macros to of.h Grant Likely
2009-10-07  4:30 ` [RFC PATCH 05/12] of: add common header for flattened device tree representation Grant Likely
2009-10-07  4:31 ` [RFC PATCH 06/12] of: merge struct boot_param_header from Microblaze and PowerPC Grant Likely
2009-10-07  4:31 ` [RFC PATCH 07/12] of: merge of_node_*_flag() and set_node_proc_entry() Grant Likely
2009-10-07  4:31 ` [RFC PATCH 08/12] of: merge of_read_number() an of_read_ulong() Grant Likely
2009-10-07  4:31 ` [RFC PATCH 09/12] of: merge of_node_get(), of_node_put() and of_find_all_nodes() Grant Likely
2009-10-07  4:32 ` [RFC PATCH 10/12] of: merge of_*_flat_dt*() functions Grant Likely
2009-10-07  4:32 ` [RFC PATCH 11/12] of: merge other miscellaneous prototypes Grant Likely
2009-10-07  4:32 ` [RFC PATCH 12/12] of: merge of_find_all_nodes() implementations Grant Likely
2009-10-07  4:49 ` [RFC PATCH 00/12] Merge common OpenFirmware device tree code Grant Likely
2009-10-07  5:18   ` Julian Calaby
     [not found]     ` <646765f40910062218s19d540f9q14c9086bedd1d9da-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-10-07 13:52       ` Sam Creasey
2009-10-07 19:30         ` Mitch Bradley
     [not found]           ` <4ACCEC67.9070106-D5eQfiDGL7eakBO8gow8eQ@public.gmane.org>
2009-10-07 20:54             ` Chris Newport
     [not found]               ` <Pine.LNX.4.60.0910072148040.11795-pb599fR3TxWvwYtD5Hs6llaTQe2KTcn/@public.gmane.org>
2009-10-07 21:09                 ` David Miller
2009-10-08  1:29                   ` Chris Newport
     [not found]                     ` <Pine.LNX.4.60.0910080155210.12519-pb599fR3TxWvwYtD5Hs6llaTQe2KTcn/@public.gmane.org>
2009-10-08  4:39                       ` David Miller
     [not found]                         ` <20091007.213915.37481688.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2009-10-08 13:24                           ` Kjetil Oftedal
2009-10-07 22:57         ` Brad Boyer
     [not found]   ` <fa686aa40910062149p5d7141e4x3ff849fd4d191f38-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-10-07  7:09     ` Rob Landley
2009-10-07 14:02       ` Grant Likely
     [not found]         ` <fa686aa40910070702j470785d2ka2621122a8e2f1fd-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-10-07 14:21           ` [microblaze-uclinux] " Michal Simek
2009-10-07  7:27     ` David Miller
     [not found]       ` <20091007.002722.168292120.davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
2009-10-07 16:39         ` Stephen Neuendorffer
2009-10-07  9:02     ` Wolfram Sang
     [not found] ` <20091007043052.16890.15975.stgit@angua>
2009-10-07  4:57   ` [RFC PATCH 05/12] of: add common header for flattened device tree representation Stephen Rothwell
2009-10-07 12:14     ` [microblaze-uclinux] " Michal Simek
     [not found]       ` <4ACC861A.7020506-pSz03upnqPeHXe+LvDLADg@public.gmane.org>
2009-10-07 13:38         ` Grant Likely
2009-10-07 14:07           ` Michal Simek
2009-10-07  5:14   ` Benjamin Herrenschmidt
2009-10-07 13:41     ` Grant Likely
2009-10-09  6:35   ` David Gibson
     [not found]     ` <20091009063534.GC12948-787xzQ0H9iRg7VrjXcPTGA@public.gmane.org>
2009-10-09  7:07       ` Grant Likely
     [not found]         ` <fa686aa40910090007lef3fddbod0c5843abfe33be5-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-10-14  4:47           ` David Gibson
     [not found] ` <20091007043154.16890.18883.stgit@angua>
2009-10-09  6:36   ` [RFC PATCH 10/12] of: merge of_*_flat_dt*() functions David Gibson
     [not found]     ` <20091009063635.GD12948-787xzQ0H9iRg7VrjXcPTGA@public.gmane.org>
2009-10-09  7:03       ` Grant Likely
2009-10-15  1:00 ` [RFC PATCH 00/12] Merge common OpenFirmware device tree code Stephen Rothwell
     [not found]   ` <20091015120007.3780c59b.sfr-3FnU+UHB4dNDw9hX6IcOSA@public.gmane.org>
2009-10-15  1:01     ` [PATCH 1/2] of: create asm/of.h Stephen Rothwell
2009-10-15  1:02       ` Stephen Rothwell [this message]
2009-10-15 17:06   ` [RFC PATCH 00/12] Merge common OpenFirmware device tree code Grant Likely
     [not found]     ` <fa686aa40910151006k43b07c30q1e43c3b1ae4af561-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2009-10-15 23:38       ` Stephen Rothwell
     [not found]         ` <20091016103829.323c89d7.sfr-3FnU+UHB4dNDw9hX6IcOSA@public.gmane.org>
2009-10-16  3:18           ` Grant Likely

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20091015120249.cf84d941.sfr@canb.auug.org.au \
    --to=sfr@canb.auug.org.au \
    --cc=davem@davemloft.net \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=grant.likely@secretlab.ca \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=microblaze-uclinux@itee.uq.edu.au \
    --cc=monstr@monstr.eu \
    --cc=sparclinux@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox