Skip to content

Commit

Permalink
cpufreq: stats: Change return type of cpufreq_stats_update() as void
Browse files Browse the repository at this point in the history
It always returns 0 and none of its callers check its return value. Make
it return void.

Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
  • Loading branch information
Viresh Kumar authored and Rafael J. Wysocki committed Jan 5, 2018
1 parent 967b87f commit d476ec4
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/cpufreq/cpufreq_stats.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,14 @@ struct cpufreq_stats {
unsigned int *trans_table;
};

static int cpufreq_stats_update(struct cpufreq_stats *stats)
static void cpufreq_stats_update(struct cpufreq_stats *stats)
{
unsigned long long cur_time = get_jiffies_64();

spin_lock(&cpufreq_stats_lock);
stats->time_in_state[stats->last_index] += cur_time - stats->last_time;
stats->last_time = cur_time;
spin_unlock(&cpufreq_stats_lock);
return 0;
}

static void cpufreq_stats_clear_table(struct cpufreq_stats *stats)
Expand Down

0 comments on commit d476ec4

Please sign in to comment.