Loading
cpufreq: intel_pstate: Read global.no_turbo under READ_ONCE()
mainline inclusion from mainline-v6.10 commit 9558fae8ce97b3b320b387dd7c88309df2c36d4d category: bugfix bugzilla: https://gitee.com/openeuler/intel-kernel/issues/IB6QC4 CVE: NA Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=9558fae8ce97b3b320b387dd7c88309df2c36d4d ------------------------------------------------- Intel-SIG: commit 9558fae8ce97 cpufreq: intel_pstate: Read global.no_turbo under READ_ONCE(). Backport intel_pstate driver update for 6.6 from 6.11 Because global.no_turbo is generally not read under intel_pstate_driver_lock make store_no_turbo() use WRITE_ONCE() for updating it (this is the only place at which it is updated except for the initialization) and make the majority of places reading it use READ_ONCE(). Also remove redundant global.turbo_disabled checks from places that depend on the 'true' value of global.no_turbo because it can only be 'true' if global.turbo_disabled is also 'true'. Signed-off-by:Rafael J. Wysocki <rafael.j.wysocki@intel.com> Acked-by:
Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> [ Yingbao Jia: amend commit log ] Signed-off-by:
Yingbao Jia <yingbao.jia@intel.com>