Skip to content

Commit

Permalink
cpufreq: SPEAr: Fix incorrect variable type
Browse files Browse the repository at this point in the history
'clk_round_rate' returns a negative error code upon failure. This
will never get detected by unsigned 'newfreq'. Make it signed.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Sachin Kamat authored and Rafael J. Wysocki committed Sep 30, 2013
1 parent 15c03dd commit bb25f13
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/cpufreq/spear-cpufreq.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ static int spear_cpufreq_target(struct cpufreq_policy *policy,
unsigned int target_freq, unsigned int relation)
{
struct cpufreq_freqs freqs;
unsigned long newfreq;
long newfreq;
struct clk *srcclk;
int index, ret, mult = 1;

Expand Down

0 comments on commit bb25f13

Please sign in to comment.