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: d46c742f82 ("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>
This commit is contained in:
Yang Yingliang 2022-08-24 17:36:57 +08:00 committed by Helge Deller
parent 80e78fcce8
commit 38238be4e8
1 changed files with 1 additions and 0 deletions

View File

@ -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;
}