diff options
author | Yang Yingliang <yangyingliang@huawei.com> | 2022-08-24 17:36:57 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2022-09-28 11:02:52 +0200 |
commit | cb9c98e43795ef7513fa21a299b8c178ab47dc1f (patch) | |
tree | c547fef807843d9efa72ecd95794961d2a31ae6f | |
parent | 63408525dc1331d6644c92273d34083be6dc0102 (diff) | |
download | linux-stable-cb9c98e43795ef7513fa21a299b8c178ab47dc1f.tar.gz linux-stable-cb9c98e43795ef7513fa21a299b8c178ab47dc1f.tar.bz2 linux-stable-cb9c98e43795ef7513fa21a299b8c178ab47dc1f.zip |
parisc: ccio-dma: Add missing iounmap in error path in ccio_probe()
[ Upstream commit 38238be4e881a5d0abbe4872b4cd6ed790be06c8 ]
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>
Signed-off-by: Sasha Levin <sashal@kernel.org>
-rw-r--r-- | drivers/parisc/ccio-dma.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/parisc/ccio-dma.c b/drivers/parisc/ccio-dma.c index 73ee74d6e7a3..2c763f9d75df 100644 --- a/drivers/parisc/ccio-dma.c +++ b/drivers/parisc/ccio-dma.c @@ -1555,6 +1555,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; } |