summaryrefslogtreecommitdiff
path: root/lib/string_helpers.c
diff options
context:
space:
mode:
authorViresh Kumar <viresh.kumar@linaro.org>2015-01-06 15:39:15 (GMT)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2015-01-23 22:06:45 (GMT)
commit490285c65e2398a533035dd9d75cb606a61ea39a (patch)
treee18fa0f20423f9838e3bafe5e7f036fc4b75ae33 /lib/string_helpers.c
parente73476949c6d1e2edd04bbf7b5bae30afa370e33 (diff)
downloadlinux-490285c65e2398a533035dd9d75cb606a61ea39a.tar.xz
cpufreq: stats: drop unnecessary locking
There is no possibility of any race on updating last_index, trans_table or total_trans as these are updated only by cpufreq_stat_notifier_trans() which will be called sequentially. The only place where locking is still relevant is: cpufreq_stats_update(), which updates time_in_state and last_time. This can be called by two thread in parallel, that may result in races. The two threads being: - sysfs read of time_in_state - and frequency transition that calls cpufreq_stat_notifier_trans(). Remove locking from the first case mentioned above. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'lib/string_helpers.c')
0 files changed, 0 insertions, 0 deletions