summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYang Yingliang <yangyingliang@huawei.com>2022-08-24 17:36:57 +0800
committerHelge Deller <deller@gmx.de>2022-09-13 08:50:31 +0200
commit38238be4e881a5d0abbe4872b4cd6ed790be06c8 (patch)
tree6952937a9638d41c1d0c4171b8d16b203bb2c323
parent80e78fcce86de0288793a0ef0f6acf37656ee4cf (diff)
downloadlinux-stable-38238be4e881a5d0abbe4872b4cd6ed790be06c8.tar.gz
linux-stable-38238be4e881a5d0abbe4872b4cd6ed790be06c8.tar.bz2
linux-stable-38238be4e881a5d0abbe4872b4cd6ed790be06c8.zip
parisc: ccio-dma: Add missing iounmap in error path in ccio_probe()
Add missing iounmap() before return from ccio_probe(), if ccio_init_resources() fails. Fixes: d46c742f827f ("parisc: ccio-dma: Handle kmalloc failure in ccio_init_resources()") Signed-off-by: Yang Yingliang <yangyingliang@huawei.com> Signed-off-by: Helge Deller <deller@gmx.de>
-rw-r--r--drivers/parisc/ccio-dma.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/parisc/ccio-dma.c b/drivers/parisc/ccio-dma.c
index f223afe47d10..a66386043aa6 100644
--- a/drivers/parisc/ccio-dma.c
+++ b/drivers/parisc/ccio-dma.c
@@ -1546,6 +1546,7 @@ static int __init ccio_probe(struct parisc_device *dev)
}
ccio_ioc_init(ioc);
if (ccio_init_resources(ioc)) {
+ iounmap(ioc->ioc_regs);
kfree(ioc);
return -ENOMEM;
}