diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2015-09-01 19:37:56 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-09-01 19:37:56 -0700 |
commit | f1a3c0b933e7ff856223d6fcd7456d403e54e4e5 (patch) | |
tree | 248904252b10d6685b5a81f2ba4dc5cf35dcec38 /drivers/base | |
parent | 089b669506ef28fae2c24a0ec21e06c02a38556b (diff) | |
parent | c8fb70a3e8dd60e31c4422bae85783cf1733f038 (diff) |
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/base')
-rw-r--r-- | drivers/base/platform.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/drivers/base/platform.c b/drivers/base/platform.c index 063f0ab15259..f80aaaf9f610 100644 --- a/drivers/base/platform.c +++ b/drivers/base/platform.c @@ -375,9 +375,7 @@ int platform_device_add(struct platform_device *pdev) while (--i >= 0) { struct resource *r = &pdev->resource[i]; - unsigned long type = resource_type(r); - - if (type == IORESOURCE_MEM || type == IORESOURCE_IO) + if (r->parent) release_resource(r); } @@ -408,9 +406,7 @@ void platform_device_del(struct platform_device *pdev) for (i = 0; i < pdev->num_resources; i++) { struct resource *r = &pdev->resource[i]; - unsigned long type = resource_type(r); - - if (type == IORESOURCE_MEM || type == IORESOURCE_IO) + if (r->parent) release_resource(r); } } |