aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-sparc64/of_device.h
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2006-07-03 13:49:45 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2006-07-03 13:49:45 -0400
commit026477c1141b67e98e3bd8bdedb7d4b88a3ecd09 (patch)
tree2624a44924c625c367f3cebf937853b9da2de282 /include/asm-sparc64/of_device.h
parent9f2fa466383ce100b90fe52cb4489d7a26bf72a9 (diff)
parent29454dde27d8e340bb1987bad9aa504af7081eba (diff)
Merge branch 'master' of /home/trondmy/kernel/linux-2.6/
Diffstat (limited to 'include/asm-sparc64/of_device.h')
-rw-r--r--include/asm-sparc64/of_device.h20
1 files changed, 18 insertions, 2 deletions
diff --git a/include/asm-sparc64/of_device.h b/include/asm-sparc64/of_device.h
index 024088ef9d27..a62c7b997d66 100644
--- a/include/asm-sparc64/of_device.h
+++ b/include/asm-sparc64/of_device.h
@@ -4,11 +4,13 @@
4 4
5#include <linux/device.h> 5#include <linux/device.h>
6#include <linux/mod_devicetable.h> 6#include <linux/mod_devicetable.h>
7#include <asm/openprom.h>
7#include <asm/prom.h> 8#include <asm/prom.h>
8 9
9extern struct bus_type isa_bus_type; 10extern struct bus_type isa_bus_type;
10extern struct bus_type ebus_bus_type; 11extern struct bus_type ebus_bus_type;
11extern struct bus_type sbus_bus_type; 12extern struct bus_type sbus_bus_type;
13extern struct bus_type of_bus_type;
12 14
13/* 15/*
14 * The of_device is a kind of "base class" that is a superset of 16 * The of_device is a kind of "base class" that is a superset of
@@ -17,11 +19,25 @@ extern struct bus_type sbus_bus_type;
17 */ 19 */
18struct of_device 20struct of_device
19{ 21{
20 struct device_node *node; /* OF device node */ 22 struct device_node *node;
21 struct device dev; /* Generic device interface */ 23 struct device dev;
24 struct resource resource[PROMREG_MAX];
25 unsigned int irqs[PROMINTR_MAX];
26 int num_irqs;
27
28 void *sysdata;
29
30 int slot;
31 int portid;
32 int clock_freq;
22}; 33};
23#define to_of_device(d) container_of(d, struct of_device, dev) 34#define to_of_device(d) container_of(d, struct of_device, dev)
24 35
36extern void __iomem *of_ioremap(struct resource *res, unsigned long offset, unsigned long size, char *name);
37extern void of_iounmap(void __iomem *base, unsigned long size);
38
39extern struct of_device *of_find_device_by_node(struct device_node *);
40
25extern const struct of_device_id *of_match_device( 41extern const struct of_device_id *of_match_device(
26 const struct of_device_id *matches, const struct of_device *dev); 42 const struct of_device_id *matches, const struct of_device *dev);
27 43