summaryrefslogtreecommitdiffstats
path: root/common/resource.c
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2014-07-31 08:38:08 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2014-09-16 08:32:09 +0200
commitdde56d42ad1763dd81a3de65b74d7387d12f6fa9 (patch)
tree888d48be1b4beaaa73195f1879a9369d84c5af88 /common/resource.c
parent82ed2054665a2c6caa7b7a69143583e051289812 (diff)
downloadbarebox-dde56d42ad1763dd81a3de65b74d7387d12f6fa9.tar.gz
resource: Let request_iomem_region return an error pointer
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'common/resource.c')
-rw-r--r--common/resource.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/common/resource.c b/common/resource.c
index 6e84bd8..fd04f26 100644
--- a/common/resource.c
+++ b/common/resource.c
@@ -125,13 +125,7 @@ struct resource iomem_resource = {
struct resource *request_iomem_region(const char *name,
resource_size_t start, resource_size_t end)
{
- struct resource *res;
-
- res = __request_region(&iomem_resource, name, start, end);
- if (IS_ERR(res))
- return NULL;
-
- return res;
+ return __request_region(&iomem_resource, name, start, end);
}
/* The root resource for the whole io-mapped io space */