diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2016-02-08 23:57:22 +0100 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2016-03-09 14:40:57 +0100 |
commit | fafd5e8ab29d965d6c7db326f2d4189dd9f3b002 (patch) | |
tree | f6e2de9cce71ab82327af711e6e2b5d0cbdc0605 /drivers/cpufreq | |
parent | 686cc637c99324ad52a6f8e59181f6407405bfe2 (diff) | |
download | linux-fafd5e8ab29d965d6c7db326f2d4189dd9f3b002.tar.bz2 |
cpufreq: governor: Drop pointless goto from cpufreq_governor_init()
It is silly to jump around "return 0", so don't do that.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Diffstat (limited to 'drivers/cpufreq')
-rw-r--r-- | drivers/cpufreq/cpufreq_governor.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/cpufreq/cpufreq_governor.c b/drivers/cpufreq/cpufreq_governor.c index 298be52adea0..d6bd402a3237 100644 --- a/drivers/cpufreq/cpufreq_governor.c +++ b/drivers/cpufreq/cpufreq_governor.c @@ -395,12 +395,11 @@ static int cpufreq_governor_init(struct cpufreq_policy *policy) ret = sysfs_create_group(get_governor_parent_kobj(policy), get_sysfs_attr(gov)); - if (ret) - goto reset_gdbs_data; + if (!ret) + return 0; - return 0; + /* Failure, so roll back. */ -reset_gdbs_data: policy->governor_data = NULL; if (!have_governor_per_policy()) |