summaryrefslogtreecommitdiffstats
path: root/kernel/memremap.c
diff options
context:
space:
mode:
authorDan Williams <dan.j.williams@intel.com>2015-09-15 02:37:48 -0400
committerDan Williams <dan.j.williams@intel.com>2015-10-09 17:00:33 -0400
commitd741314fe8318c1af497b8cf04ea3976b9509eca (patch)
tree420ecedb80a8c41a6974561efd713b85949fc3e5 /kernel/memremap.c
parenta639315d6c536c806724c9328941a2517507e3e3 (diff)
downloadlinux-stable-d741314fe8318c1af497b8cf04ea3976b9509eca.tar.gz
linux-stable-d741314fe8318c1af497b8cf04ea3976b9509eca.tar.bz2
linux-stable-d741314fe8318c1af497b8cf04ea3976b9509eca.zip
devm_memunmap: use devres_release()
Remove open coded call to memunmap. Cc: Christoph Hellwig <hch@lst.de> Cc: Ross Zwisler <ross.zwisler@linux.intel.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'kernel/memremap.c')
-rw-r--r--kernel/memremap.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/kernel/memremap.c b/kernel/memremap.c
index 72b0c66628b6..0756273437e0 100644
--- a/kernel/memremap.c
+++ b/kernel/memremap.c
@@ -131,9 +131,8 @@ EXPORT_SYMBOL(devm_memremap);
void devm_memunmap(struct device *dev, void *addr)
{
- WARN_ON(devres_destroy(dev, devm_memremap_release, devm_memremap_match,
- addr));
- memunmap(addr);
+ WARN_ON(devres_release(dev, devm_memremap_release,
+ devm_memremap_match, addr));
}
EXPORT_SYMBOL(devm_memunmap);