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>
This commit is contained in:
parent
a639315d6c
commit
d741314fe8
|
@ -131,9 +131,8 @@ EXPORT_SYMBOL(devm_memremap);
|
||||||
|
|
||||||
void devm_memunmap(struct device *dev, void *addr)
|
void devm_memunmap(struct device *dev, void *addr)
|
||||||
{
|
{
|
||||||
WARN_ON(devres_destroy(dev, devm_memremap_release, devm_memremap_match,
|
WARN_ON(devres_release(dev, devm_memremap_release,
|
||||||
addr));
|
devm_memremap_match, addr));
|
||||||
memunmap(addr);
|
|
||||||
}
|
}
|
||||||
EXPORT_SYMBOL(devm_memunmap);
|
EXPORT_SYMBOL(devm_memunmap);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue