summaryrefslogtreecommitdiffstats
path: root/drivers/of
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2015-09-01 19:37:56 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2015-09-01 19:37:56 -0700
commitf1a3c0b933e7ff856223d6fcd7456d403e54e4e5 (patch)
tree248904252b10d6685b5a81f2ba4dc5cf35dcec38 /drivers/of
parent089b669506ef28fae2c24a0ec21e06c02a38556b (diff)
parentc8fb70a3e8dd60e31c4422bae85783cf1733f038 (diff)
downloadlinux-f1a3c0b933e7ff856223d6fcd7456d403e54e4e5.tar.bz2
Merge tag 'devicetree-for-4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux
Pull devicetree updates from Rob Herring: - added Frank Rowand as DT maintainer in preparation for Grant's retirement. - generic MSI binding documentation and a few other minor doc updates - fix long standing issue with DT platorm device unregistration - fix loop forever bug in of_find_matching_node_by_address() * tag 'devicetree-for-4.3' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux: MAINTAINERS: Add Frank Rowand as DT maintainer mtd: nand: pxa3xx: add optional dma for pxa architecture Documentation: DT: cpsw: document missing compatible Docs: dt: add generic MSI bindings drivercore: Fix unregistration path of platform devices of/address: Don't loop forever in of_find_matching_node_by_address(). of: Add vendor prefix for JEDEC Solid State Technology Association of/platform: add function to populate default bus of: Add vendor prefix for Sharp Corporation
Diffstat (limited to 'drivers/of')
-rw-r--r--drivers/of/address.c6
-rw-r--r--drivers/of/platform.c9
2 files changed, 12 insertions, 3 deletions
diff --git a/drivers/of/address.c b/drivers/of/address.c
index 8bfda6ade2c0..384574c3987c 100644
--- a/drivers/of/address.c
+++ b/drivers/of/address.c
@@ -845,10 +845,10 @@ struct device_node *of_find_matching_node_by_address(struct device_node *from,
struct resource res;
while (dn) {
- if (of_address_to_resource(dn, 0, &res))
- continue;
- if (res.start == base_address)
+ if (!of_address_to_resource(dn, 0, &res) &&
+ res.start == base_address)
return dn;
+
dn = of_find_matching_node(dn, matches);
}
diff --git a/drivers/of/platform.c b/drivers/of/platform.c
index 8a002d6151f2..1001efaedcb8 100644
--- a/drivers/of/platform.c
+++ b/drivers/of/platform.c
@@ -457,6 +457,15 @@ int of_platform_populate(struct device_node *root,
}
EXPORT_SYMBOL_GPL(of_platform_populate);
+int of_platform_default_populate(struct device_node *root,
+ const struct of_dev_auxdata *lookup,
+ struct device *parent)
+{
+ return of_platform_populate(root, of_default_bus_match_table, lookup,
+ parent);
+}
+EXPORT_SYMBOL_GPL(of_platform_default_populate);
+
static int of_platform_device_destroy(struct device *dev, void *data)
{
/* Do not touch devices not populated from the device tree */