oprofile, ARM: Remove some goto statements
authorRobert Richter <robert.richter@amd.com>
Fri, 27 Aug 2010 12:32:41 +0000 (14:32 +0200)
committerRobert Richter <robert.richter@amd.com>
Mon, 11 Oct 2010 17:34:03 +0000 (19:34 +0200)
This patch removes some unnecessary goto statements.

Acked-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Robert Richter <robert.richter@amd.com>
drivers/oprofile/oprofile_perf.c

index f3d3df229a43896dc9a279b4b5f51de69d7d831e..6853634c46814b617d01a5e5c5affa1b09c1a8dd 100644 (file)
@@ -117,11 +117,10 @@ static int op_perf_start(void)
                for (event = 0; event < num_counters; ++event) {
                        ret = op_create_counter(cpu, event);
                        if (ret)
-                               goto out;
+                               return ret;
                }
        }
 
-out:
        return ret;
 }
 
@@ -224,7 +223,7 @@ static int __init init_driverfs(void)
 
        ret = platform_driver_register(&oprofile_driver);
        if (ret)
-               goto out;
+               return ret;
 
        oprofile_pdev = platform_device_register_simple(
                                oprofile_driver.driver.name, 0, NULL, 0);
@@ -233,7 +232,6 @@ static int __init init_driverfs(void)
                platform_driver_unregister(&oprofile_driver);
        }
 
-out:
        return ret;
 }