Skip to content

Commit

Permalink
cpufreq: ondemand: Simplify od_update() slightly
Browse files Browse the repository at this point in the history
Drop some lines of code from od_update() by arranging the statements
in there in a more logical way.

No functional changes.

Signed-off-by: Rafael J. Wysocki <[email protected]>
Acked-by: Viresh Kumar <[email protected]>
  • Loading branch information
rafaeljw committed Mar 9, 2016
1 parent 07aa440 commit a7f35cf
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions drivers/cpufreq/cpufreq_ondemand.c
Original file line number Diff line number Diff line change
Expand Up @@ -175,14 +175,11 @@ static void od_update(struct cpufreq_policy *policy)
/* No longer fully busy, reset rate_mult */
policy_dbs->rate_mult = 1;

if (!od_tuners->powersave_bias) {
__cpufreq_driver_target(policy, freq_next,
CPUFREQ_RELATION_C);
return;
}

freq_next = od_ops.powersave_bias_target(policy, freq_next,
CPUFREQ_RELATION_L);
if (od_tuners->powersave_bias)
freq_next = od_ops.powersave_bias_target(policy,
freq_next,
CPUFREQ_RELATION_L);

__cpufreq_driver_target(policy, freq_next, CPUFREQ_RELATION_C);
}
}
Expand Down

0 comments on commit a7f35cf

Please sign in to comment.