aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sparc64
diff options
context:
space:
mode:
authorStephen Rothwell <sfr@canb.auug.org.au>2007-04-30 03:43:56 -0400
committerStephen Rothwell <sfr@canb.auug.org.au>2007-07-20 00:24:53 -0400
commit37b7754aab9a6ad7ecbba45c87f8d8a1f81b3bcc (patch)
tree8835a766b195fe2b25dce60ceff0f2713fe545fe /arch/sparc64
parentf898f8dbcec4848cddb8c5be2d0affd75779ebe2 (diff)
[SPARC/64] Rename some functions like PowerPC
This is to make the of merge easier. Also rename of_bus_type. Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Acked-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc64')
-rw-r--r--arch/sparc64/kernel/auxio.c2
-rw-r--r--arch/sparc64/kernel/of_device.c50
-rw-r--r--arch/sparc64/kernel/power.c2
-rw-r--r--arch/sparc64/kernel/time.c2
4 files changed, 28 insertions, 28 deletions
diff --git a/arch/sparc64/kernel/auxio.c b/arch/sparc64/kernel/auxio.c
index 826118ee53d5..7b379761e9f8 100644
--- a/arch/sparc64/kernel/auxio.c
+++ b/arch/sparc64/kernel/auxio.c
@@ -155,7 +155,7 @@ static struct of_platform_driver auxio_driver = {
155 155
156static int __init auxio_init(void) 156static int __init auxio_init(void)
157{ 157{
158 return of_register_driver(&auxio_driver, &of_bus_type); 158 return of_register_driver(&auxio_driver, &of_platform_bus_type);
159} 159}
160 160
161/* Must be after subsys_initcall() so that busses are probed. Must 161/* Must be after subsys_initcall() so that busses are probed. Must
diff --git a/arch/sparc64/kernel/of_device.c b/arch/sparc64/kernel/of_device.c
index 68927bc3d3a9..485f8579899a 100644
--- a/arch/sparc64/kernel/of_device.c
+++ b/arch/sparc64/kernel/of_device.c
@@ -21,7 +21,7 @@ static int of_platform_bus_match(struct device *dev, struct device_driver *drv)
21 return of_match_device(matches, of_dev) != NULL; 21 return of_match_device(matches, of_dev) != NULL;
22} 22}
23 23
24static int of_device_probe(struct device *dev) 24static int of_platform_device_probe(struct device *dev)
25{ 25{
26 int error = -ENODEV; 26 int error = -ENODEV;
27 struct of_platform_driver *drv; 27 struct of_platform_driver *drv;
@@ -45,7 +45,7 @@ static int of_device_probe(struct device *dev)
45 return error; 45 return error;
46} 46}
47 47
48static int of_device_remove(struct device *dev) 48static int of_platform_device_remove(struct device *dev)
49{ 49{
50 struct of_device * of_dev = to_of_device(dev); 50 struct of_device * of_dev = to_of_device(dev);
51 struct of_platform_driver * drv = to_of_platform_driver(dev->driver); 51 struct of_platform_driver * drv = to_of_platform_driver(dev->driver);
@@ -55,7 +55,7 @@ static int of_device_remove(struct device *dev)
55 return 0; 55 return 0;
56} 56}
57 57
58static int of_device_suspend(struct device *dev, pm_message_t state) 58static int of_platform_device_suspend(struct device *dev, pm_message_t state)
59{ 59{
60 struct of_device * of_dev = to_of_device(dev); 60 struct of_device * of_dev = to_of_device(dev);
61 struct of_platform_driver * drv = to_of_platform_driver(dev->driver); 61 struct of_platform_driver * drv = to_of_platform_driver(dev->driver);
@@ -66,7 +66,7 @@ static int of_device_suspend(struct device *dev, pm_message_t state)
66 return error; 66 return error;
67} 67}
68 68
69static int of_device_resume(struct device * dev) 69static int of_platform_device_resume(struct device * dev)
70{ 70{
71 struct of_device * of_dev = to_of_device(dev); 71 struct of_device * of_dev = to_of_device(dev);
72 struct of_platform_driver * drv = to_of_platform_driver(dev->driver); 72 struct of_platform_driver * drv = to_of_platform_driver(dev->driver);
@@ -112,7 +112,7 @@ static int node_match(struct device *dev, void *data)
112 112
113struct of_device *of_find_device_by_node(struct device_node *dp) 113struct of_device *of_find_device_by_node(struct device_node *dp)
114{ 114{
115 struct device *dev = bus_find_device(&of_bus_type, NULL, 115 struct device *dev = bus_find_device(&of_platform_bus_type, NULL,
116 dp, node_match); 116 dp, node_match);
117 117
118 if (dev) 118 if (dev)
@@ -126,20 +126,20 @@ EXPORT_SYMBOL(of_find_device_by_node);
126struct bus_type isa_bus_type = { 126struct bus_type isa_bus_type = {
127 .name = "isa", 127 .name = "isa",
128 .match = of_platform_bus_match, 128 .match = of_platform_bus_match,
129 .probe = of_device_probe, 129 .probe = of_platform_device_probe,
130 .remove = of_device_remove, 130 .remove = of_platform_device_remove,
131 .suspend = of_device_suspend, 131 .suspend = of_platform_device_suspend,
132 .resume = of_device_resume, 132 .resume = of_platform_device_resume,
133}; 133};
134EXPORT_SYMBOL(isa_bus_type); 134EXPORT_SYMBOL(isa_bus_type);
135 135
136struct bus_type ebus_bus_type = { 136struct bus_type ebus_bus_type = {
137 .name = "ebus", 137 .name = "ebus",
138 .match = of_platform_bus_match, 138 .match = of_platform_bus_match,
139 .probe = of_device_probe, 139 .probe = of_platform_device_probe,
140 .remove = of_device_remove, 140 .remove = of_platform_device_remove,
141 .suspend = of_device_suspend, 141 .suspend = of_platform_device_suspend,
142 .resume = of_device_resume, 142 .resume = of_platform_device_resume,
143}; 143};
144EXPORT_SYMBOL(ebus_bus_type); 144EXPORT_SYMBOL(ebus_bus_type);
145#endif 145#endif
@@ -148,23 +148,23 @@ EXPORT_SYMBOL(ebus_bus_type);
148struct bus_type sbus_bus_type = { 148struct bus_type sbus_bus_type = {
149 .name = "sbus", 149 .name = "sbus",
150 .match = of_platform_bus_match, 150 .match = of_platform_bus_match,
151 .probe = of_device_probe, 151 .probe = of_platform_device_probe,
152 .remove = of_device_remove, 152 .remove = of_platform_device_remove,
153 .suspend = of_device_suspend, 153 .suspend = of_platform_device_suspend,
154 .resume = of_device_resume, 154 .resume = of_platform_device_resume,
155}; 155};
156EXPORT_SYMBOL(sbus_bus_type); 156EXPORT_SYMBOL(sbus_bus_type);
157#endif 157#endif
158 158
159struct bus_type of_bus_type = { 159struct bus_type of_platform_bus_type = {
160 .name = "of", 160 .name = "of",
161 .match = of_platform_bus_match, 161 .match = of_platform_bus_match,
162 .probe = of_device_probe, 162 .probe = of_platform_device_probe,
163 .remove = of_device_remove, 163 .remove = of_platform_device_remove,
164 .suspend = of_device_suspend, 164 .suspend = of_platform_device_suspend,
165 .resume = of_device_resume, 165 .resume = of_platform_device_resume,
166}; 166};
167EXPORT_SYMBOL(of_bus_type); 167EXPORT_SYMBOL(of_platform_bus_type);
168 168
169static inline u64 of_read_addr(const u32 *cell, int size) 169static inline u64 of_read_addr(const u32 *cell, int size)
170{ 170{
@@ -882,7 +882,7 @@ static struct of_device * __init scan_one_device(struct device_node *dp,
882 op->irqs[i] = build_one_device_irq(op, parent, op->irqs[i]); 882 op->irqs[i] = build_one_device_irq(op, parent, op->irqs[i]);
883 883
884 op->dev.parent = parent; 884 op->dev.parent = parent;
885 op->dev.bus = &of_bus_type; 885 op->dev.bus = &of_platform_bus_type;
886 if (!parent) 886 if (!parent)
887 strcpy(op->dev.bus_id, "root"); 887 strcpy(op->dev.bus_id, "root");
888 else 888 else
@@ -926,7 +926,7 @@ static int __init of_bus_driver_init(void)
926{ 926{
927 int err; 927 int err;
928 928
929 err = bus_register(&of_bus_type); 929 err = bus_register(&of_platform_bus_type);
930#ifdef CONFIG_PCI 930#ifdef CONFIG_PCI
931 if (!err) 931 if (!err)
932 err = bus_register(&isa_bus_type); 932 err = bus_register(&isa_bus_type);
diff --git a/arch/sparc64/kernel/power.c b/arch/sparc64/kernel/power.c
index 8dd4294ad21e..fdc0d0b5a910 100644
--- a/arch/sparc64/kernel/power.c
+++ b/arch/sparc64/kernel/power.c
@@ -170,6 +170,6 @@ static struct of_platform_driver power_driver = {
170 170
171void __init power_init(void) 171void __init power_init(void)
172{ 172{
173 of_register_driver(&power_driver, &of_bus_type); 173 of_register_driver(&power_driver, &of_platform_bus_type);
174 return; 174 return;
175} 175}
diff --git a/arch/sparc64/kernel/time.c b/arch/sparc64/kernel/time.c
index 62e316ab1339..592ffcd57605 100644
--- a/arch/sparc64/kernel/time.c
+++ b/arch/sparc64/kernel/time.c
@@ -835,7 +835,7 @@ static int __init clock_init(void)
835 return 0; 835 return 0;
836 } 836 }
837 837
838 return of_register_driver(&clock_driver, &of_bus_type); 838 return of_register_driver(&clock_driver, &of_platform_bus_type);
839} 839}
840 840
841/* Must be after subsys_initcall() so that busses are probed. Must 841/* Must be after subsys_initcall() so that busses are probed. Must