aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorNicolas Pitre <nicolas.pitre@linaro.org>2011-03-29 17:09:00 -0400
committerNicolas Pitre <nicolas.pitre@linaro.org>2011-03-29 17:09:00 -0400
commitdf1b3b8f2a37667b7f81bb6bc22a4b4110ac5a2e (patch)
treef9b5c650969eed77c90300403fb3d6cae2403b77 /include
parent58b6cf28da2fb962aca89bf82b196fa398521f40 (diff)
parent9d51c816166a8c7773143e4a161f54cbb9899019 (diff)
Merge branch 'devicetree/arm-linaro-2.6.38-rebuilt' of git://git.secretlab.ca/git/linux-2.6 into linaro-2.6.38
Diffstat (limited to 'include')
-rw-r--r--include/linux/device.h7
-rw-r--r--include/linux/i2c.h2
-rw-r--r--include/linux/of.h4
-rw-r--r--include/linux/of_address.h1
-rw-r--r--include/linux/of_platform.h8
5 files changed, 10 insertions, 12 deletions
diff --git a/include/linux/device.h b/include/linux/device.h
index 1bf5cf0b451..ca5d25225aa 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -128,9 +128,7 @@ struct device_driver {
bool suppress_bind_attrs; /* disables bind/unbind via sysfs */
-#if defined(CONFIG_OF)
const struct of_device_id *of_match_table;
-#endif
int (*probe) (struct device *dev);
int (*remove) (struct device *dev);
@@ -441,9 +439,8 @@ struct device {
override */
/* arch specific additions */
struct dev_archdata archdata;
-#ifdef CONFIG_OF
- struct device_node *of_node;
-#endif
+
+ struct device_node *of_node; /* associated device tree node */
dev_t devt; /* dev_t, creates the sysfs "dev" */
diff --git a/include/linux/i2c.h b/include/linux/i2c.h
index 903576df88d..06a8d9c7de9 100644
--- a/include/linux/i2c.h
+++ b/include/linux/i2c.h
@@ -258,9 +258,7 @@ struct i2c_board_info {
unsigned short addr;
void *platform_data;
struct dev_archdata *archdata;
-#ifdef CONFIG_OF
struct device_node *of_node;
-#endif
int irq;
};
diff --git a/include/linux/of.h b/include/linux/of.h
index cad7cf0ab27..d9dd664a6a9 100644
--- a/include/linux/of.h
+++ b/include/linux/of.h
@@ -23,8 +23,6 @@
#include <asm/byteorder.h>
-#ifdef CONFIG_OF
-
typedef u32 phandle;
typedef u32 ihandle;
@@ -65,6 +63,8 @@ struct device_node {
#endif
};
+#ifdef CONFIG_OF
+
/* Pointer for first entry in chain of all nodes. */
extern struct device_node *allnodes;
extern struct device_node *of_chosen;
diff --git a/include/linux/of_address.h b/include/linux/of_address.h
index 2feda6ee614..6711d5f8bcb 100644
--- a/include/linux/of_address.h
+++ b/include/linux/of_address.h
@@ -3,6 +3,7 @@
#include <linux/ioport.h>
#include <linux/of.h>
+extern int of_address_count(struct device_node *np);
extern u64 of_translate_address(struct device_node *np, const __be32 *addr);
extern int of_address_to_resource(struct device_node *dev, int index,
struct resource *r);
diff --git a/include/linux/of_platform.h b/include/linux/of_platform.h
index a68716ad38c..bc111d589be 100644
--- a/include/linux/of_platform.h
+++ b/include/linux/of_platform.h
@@ -68,12 +68,14 @@ extern struct platform_device *of_platform_device_create(struct device_node *np,
const char *bus_id,
struct device *parent);
-/* pseudo "matches" value to not do deep probe */
-#define OF_NO_DEEP_PROBE ((struct of_device_id *)-1)
-
+extern void of_platform_prepare(struct device_node *root,
+ const struct of_device_id *matches);
extern int of_platform_bus_probe(struct device_node *root,
const struct of_device_id *matches,
struct device *parent);
+extern int of_platform_populate(struct device_node *root,
+ const struct of_device_id *matches,
+ struct device *parent);
#endif /* !CONFIG_SPARC */
#endif /* CONFIG_OF_DEVICE */