[IA64] Fix missing iounmap in error path in cyclone.c
authorJulia Lawall <julia@diku.dk>
Fri, 27 Aug 2010 21:01:30 +0000 (23:01 +0200)
committerTony Luck <tony.luck@intel.com>
Thu, 23 Sep 2010 21:32:09 +0000 (14:32 -0700)
By moving the iounmap up above the test, it takes place whether the test
succeeds or fails.

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Tony Luck <tony.luck@intel.com>
arch/ia64/kernel/cyclone.c

index 71e3586..d52f1f7 100644 (file)
@@ -59,13 +59,13 @@ int __init init_cyclone_clock(void)
                return -ENODEV;
        }
        base = readq(reg);
+       iounmap(reg);
        if(!base){
                printk(KERN_ERR "Summit chipset: Could not find valid CBAR"
                                " value.\n");
                use_cyclone = 0;
                return -ENODEV;
        }
-       iounmap(reg);
 
        /* setup PMCC */
        offset = (base + CYCLONE_PMCC_OFFSET);