summaryrefslogtreecommitdiffstats
path: root/arch/sparc/kernel/of_device_common.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2010-07-22 16:04:30 -0600
committerGrant Likely <grant.likely@secretlab.ca>2010-07-24 09:58:22 -0600
commitcd4cd7306a403f62ef3ca783b9d1cf2a03e595ed (patch)
tree2eceb6990f5a0097f158c91316ee93fc2db5282d /arch/sparc/kernel/of_device_common.c
parenta454dc50590c6d758abba016a303a221f2f1b4b8 (diff)
downloadblackbird-op-linux-cd4cd7306a403f62ef3ca783b9d1cf2a03e595ed.tar.gz
blackbird-op-linux-cd4cd7306a403f62ef3ca783b9d1cf2a03e595ed.zip
sparc: remove references to of_device and to_of_device
of_device is just a #define alias to platform_device. This patch replaces all references to it with platform_device. Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc/kernel/of_device_common.c')
-rw-r--r--arch/sparc/kernel/of_device_common.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/arch/sparc/kernel/of_device_common.c b/arch/sparc/kernel/of_device_common.c
index 2a5c639e4c3f..e80729bba028 100644
--- a/arch/sparc/kernel/of_device_common.c
+++ b/arch/sparc/kernel/of_device_common.c
@@ -13,19 +13,19 @@
static int node_match(struct device *dev, void *data)
{
- struct of_device *op = to_of_device(dev);
+ struct platform_device *op = to_platform_device(dev);
struct device_node *dp = data;
return (op->dev.of_node == dp);
}
-struct of_device *of_find_device_by_node(struct device_node *dp)
+struct platform_device *of_find_device_by_node(struct device_node *dp)
{
struct device *dev = bus_find_device(&platform_bus_type, NULL,
dp, node_match);
if (dev)
- return to_of_device(dev);
+ return to_platform_device(dev);
return NULL;
}
@@ -33,7 +33,7 @@ EXPORT_SYMBOL(of_find_device_by_node);
unsigned int irq_of_parse_and_map(struct device_node *node, int index)
{
- struct of_device *op = of_find_device_by_node(node);
+ struct platform_device *op = of_find_device_by_node(node);
if (!op || index >= op->archdata.num_irqs)
return 0;
@@ -43,16 +43,16 @@ unsigned int irq_of_parse_and_map(struct device_node *node, int index)
EXPORT_SYMBOL(irq_of_parse_and_map);
/* Take the archdata values for IOMMU, STC, and HOSTDATA found in
- * BUS and propagate to all child of_device objects.
+ * BUS and propagate to all child platform_device objects.
*/
-void of_propagate_archdata(struct of_device *bus)
+void of_propagate_archdata(struct platform_device *bus)
{
struct dev_archdata *bus_sd = &bus->dev.archdata;
struct device_node *bus_dp = bus->dev.of_node;
struct device_node *dp;
for (dp = bus_dp->child; dp; dp = dp->sibling) {
- struct of_device *op = of_find_device_by_node(dp);
+ struct platform_device *op = of_find_device_by_node(dp);
op->dev.archdata.iommu = bus_sd->iommu;
op->dev.archdata.stc = bus_sd->stc;
OpenPOWER on IntegriCloud