mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH V2] cpu/SMT: Fix cpu_smt_possible() comment
@ 2023-07-28 15:53 Zhang Rui
  2023-07-31 15:35 ` [tip: smp/core] " tip-bot2 for Zhang Rui
  0 siblings, 1 reply; 2+ messages in thread
From: Zhang Rui @ 2023-07-28 15:53 UTC (permalink / raw)
  To: tglx, peterz; +Cc: linux-kernel, vkuznets

Commit e1572f1d08be ("cpu/SMT: create and export cpu_smt_possible()")
introduces cpu_smt_possible() to represent if SMT is theoretically
possible. It returns true when SMT is supported and not forcefully
disabled ('nosmt=force'). But the comment of it says "Returns true if
SMT is not supported of forcefully (irreversibly) disabled", which is
wrong. Fix that comment accordingly.

Signed-off-by: Zhang Rui <rui.zhang@intel.com>
Reviewed-by: Vitaly Kuznetsov <vkuznets@redhat.com>
---
Changes since V1
 - rephrase the changelog
---
 kernel/cpu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/cpu.c b/kernel/cpu.c
index 88a7ede322bd..050dda751fc3 100644
--- a/kernel/cpu.c
+++ b/kernel/cpu.c
@@ -642,7 +642,7 @@ static inline bool cpu_smt_allowed(unsigned int cpu)
 	return !cpumask_test_cpu(cpu, &cpus_booted_once_mask);
 }
 
-/* Returns true if SMT is not supported of forcefully (irreversibly) disabled */
+/* Returns true if SMT is supported and not forcefully (irreversibly) disabled */
 bool cpu_smt_possible(void)
 {
 	return cpu_smt_control != CPU_SMT_FORCE_DISABLED &&
-- 
2.34.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2023-07-31 15:36 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-28 15:53 [PATCH V2] cpu/SMT: Fix cpu_smt_possible() comment Zhang Rui
2023-07-31 15:35 ` [tip: smp/core] " tip-bot2 for Zhang Rui

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®