diff options
author | Breno Leitao <leitao@debian.org> | 2024-10-31 14:06:16 +0300 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2025-03-03 14:48:17 +0300 |
commit | 2a08b832712980b9eb0e913d64a42c74fc56319b (patch) | |
tree | 9f07375026fbd7854e525f05e5ef9eeaf4a17277 /tools/perf/scripts/python/parallel-perf.py | |
parent | b8ce25df2999ac6a135ce1bd14b7243030a1338a (diff) | |
download | linux-2a08b832712980b9eb0e913d64a42c74fc56319b.tar.xz |
x86/bugs: Use the cpu_smt_possible() helper instead of open-coded code
There is a helper function to check if SMT is available. Use this helper
instead of performing the check manually.
The helper function cpu_smt_possible() does exactly the same thing as
was being done manually inside spectre_v2_user_select_mitigation().
Specifically, it returns false if CONFIG_SMP is disabled, otherwise
it checks the cpu_smt_control global variable.
This change improves code consistency and reduces duplication.
No change in functionality intended.
Signed-off-by: Breno Leitao <leitao@debian.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Reviewed-by: Pawan Gupta <pawan.kumar.gupta@linux.intel.com>
Cc: David Kaplan <David.Kaplan@amd.com>
Link: https://lore.kernel.org/r/20241031-x86_bugs_last_v2-v2-1-b7ff1dab840e@debian.org
Diffstat (limited to 'tools/perf/scripts/python/parallel-perf.py')
0 files changed, 0 insertions, 0 deletions