mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 11:26:02 +09:00
cpufreq: powernow-k8: Use related_cpus instead of cpus in driver.exit()
[ Upstream commit03997da042] Since the 'cpus' field of policy structure will become empty in the cpufreq core API, it is better to use 'related_cpus' in the exit() callback of driver. Fixes:c3274763bf("cpufreq: powernow-k8: Initialize per-cpu data-structures properly") Signed-off-by: Liao Chang <liaochang1@huawei.com> Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
133a1f45b9
commit
920b2f99bc
@@ -1101,7 +1101,8 @@ static int powernowk8_cpu_exit(struct cpufreq_policy *pol)
|
|||||||
|
|
||||||
kfree(data->powernow_table);
|
kfree(data->powernow_table);
|
||||||
kfree(data);
|
kfree(data);
|
||||||
for_each_cpu(cpu, pol->cpus)
|
/* pol->cpus will be empty here, use related_cpus instead. */
|
||||||
|
for_each_cpu(cpu, pol->related_cpus)
|
||||||
per_cpu(powernow_data, cpu) = NULL;
|
per_cpu(powernow_data, cpu) = NULL;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
Reference in New Issue
Block a user