Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mips: Vr41xx: add missing iounmap() on error in vr41xx_pciu_init()

add missing iounmap() of pciu_base on error when failed to init
io_map_base.

Signed-off-by: Qinglang Miao <miaoqinglang@huawei.com>
Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>

authored by

Qinglang Miao and committed by
Thomas Bogendoerfer
c424dc4c 2673ecf9

+3 -1
+3 -1
arch/mips/pci/pci-vr41xx.c
··· 293 293 master = setup->master_io; 294 294 io_map_base = ioremap(master->bus_base_address, 295 295 resource_size(res)); 296 - if (!io_map_base) 296 + if (!io_map_base) { 297 + iounmap(pciu_base); 297 298 return -EBUSY; 299 + } 298 300 299 301 vr41xx_pci_controller.io_map_base = (unsigned long)io_map_base; 300 302 }