mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH RESEND] x86/platform/uv: use str_enabled_disabled in uv_nmi_setup_hubless_intr
@ 2026-05-04 18:19 Thorsten Blum
  2026-06-02 23:12 ` [tip: x86/cleanups] x86/platform/uv: Use str_enabled_disabled() in uv_nmi_setup_hubless_intr() tip-bot2 for Thorsten Blum
  0 siblings, 1 reply; 3+ messages in thread
From: Thorsten Blum @ 2026-05-04 18:19 UTC (permalink / raw)
  To: Steve Wahl, Justin Ernst, Kyle Meyer, Dimitri Sivanich,
	Russ Anderson, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	Dave Hansen, x86, H. Peter Anvin
  Cc: Thorsten Blum, linux-kernel

Replace hard-coded strings with the str_enabled_disabled() helper. This
unifies the output and helps the linker with deduplication, which can
result in a smaller binary. Additionally, silence the following
Coccinelle/coccicheck warning reported by string_choices.cocci:

  opportunity for str_enabled_disabled(uv_pch_intr_now_enabled)

Reviewed-by: Kyle Meyer <kyle.meyer@hpe.com>
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 arch/x86/platform/uv/uv_nmi.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/x86/platform/uv/uv_nmi.c b/arch/x86/platform/uv/uv_nmi.c
index 5c50e550ab63..565ab43fa6b4 100644
--- a/arch/x86/platform/uv/uv_nmi.c
+++ b/arch/x86/platform/uv/uv_nmi.c
@@ -18,6 +18,7 @@
 #include <linux/sched/debug.h>
 #include <linux/slab.h>
 #include <linux/string.h>
+#include <linux/string_choices.h>
 #include <linux/clocksource.h>
 
 #include <asm/apic.h>
@@ -340,7 +341,7 @@ static void uv_nmi_setup_hubless_intr(void)
 		uv_pch_intr_now_enabled ? GPIROUTNMI : 0);
 
 	nmi_debug("UV:NMI: GPP_D_0 interrupt %s\n",
-		uv_pch_intr_now_enabled ? "enabled" : "disabled");
+		str_enabled_disabled(uv_pch_intr_now_enabled));
 }
 
 static struct init_nmi {

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

* [tip: x86/cleanups] x86/platform/uv: Use str_enabled_disabled() in uv_nmi_setup_hubless_intr()
  2026-05-04 18:19 [PATCH RESEND] x86/platform/uv: use str_enabled_disabled in uv_nmi_setup_hubless_intr Thorsten Blum
@ 2026-06-02 23:12 ` tip-bot2 for Thorsten Blum
  0 siblings, 0 replies; 3+ messages in thread
From: tip-bot2 for Thorsten Blum @ 2026-06-02 23:12 UTC (permalink / raw)
  To: linux-tip-commits
  Cc: Thorsten Blum, Borislav Petkov (AMD), Kyle Meyer, x86, linux-kernel

The following commit has been merged into the x86/cleanups branch of tip:

Commit-ID:     d022ff2557accbc7e169e4812bd9899e7c77fb5c
Gitweb:        https://git.kernel.org/tip/d022ff2557accbc7e169e4812bd9899e7c77fb5c
Author:        Thorsten Blum <thorsten.blum@linux.dev>
AuthorDate:    Mon, 04 May 2026 20:19:46 +02:00
Committer:     Borislav Petkov (AMD) <bp@alien8.de>
CommitterDate: Tue, 02 Jun 2026 13:57:38 -07:00

x86/platform/uv: Use str_enabled_disabled() in uv_nmi_setup_hubless_intr()

Replace hard-coded strings with the str_enabled_disabled() helper. This
unifies the output and helps the linker with deduplication, which can result
in a smaller binary. Additionally, address the following Coccinelle/coccicheck
warning reported by string_choices.cocci:

  opportunity for str_enabled_disabled(uv_pch_intr_now_enabled)

Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Kyle Meyer <kyle.meyer@hpe.com>
Link: https://patch.msgid.link/20260504181945.143928-2-thorsten.blum@linux.dev
---
 arch/x86/platform/uv/uv_nmi.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/x86/platform/uv/uv_nmi.c b/arch/x86/platform/uv/uv_nmi.c
index 5c50e55..565ab43 100644
--- a/arch/x86/platform/uv/uv_nmi.c
+++ b/arch/x86/platform/uv/uv_nmi.c
@@ -18,6 +18,7 @@
 #include <linux/sched/debug.h>
 #include <linux/slab.h>
 #include <linux/string.h>
+#include <linux/string_choices.h>
 #include <linux/clocksource.h>
 
 #include <asm/apic.h>
@@ -340,7 +341,7 @@ static void uv_nmi_setup_hubless_intr(void)
 		uv_pch_intr_now_enabled ? GPIROUTNMI : 0);
 
 	nmi_debug("UV:NMI: GPP_D_0 interrupt %s\n",
-		uv_pch_intr_now_enabled ? "enabled" : "disabled");
+		str_enabled_disabled(uv_pch_intr_now_enabled));
 }
 
 static struct init_nmi {

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

* [PATCH RESEND] x86/platform/uv: Use str_enabled_disabled in uv_nmi_setup_hubless_intr
@ 2025-11-22 11:53 Thorsten Blum
  0 siblings, 0 replies; 3+ messages in thread
From: Thorsten Blum @ 2025-11-22 11:53 UTC (permalink / raw)
  To: Steve Wahl, Justin Ernst, Kyle Meyer, Dimitri Sivanich,
	Russ Anderson, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
	Dave Hansen, x86, H. Peter Anvin
  Cc: Thorsten Blum, linux-kernel

Replace hard-coded strings with the str_enabled_disabled() helper. This
unifies the output and helps the linker with deduplication, which can
result in a smaller binary. Additionally, silence the following
Coccinelle/coccicheck warning reported by string_choices.cocci:

  opportunity for str_enabled_disabled(uv_pch_intr_now_enabled)

Reviewed-by: Kyle Meyer <kyle.meyer@hpe.com>
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 arch/x86/platform/uv/uv_nmi.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/x86/platform/uv/uv_nmi.c b/arch/x86/platform/uv/uv_nmi.c
index 5c50e550ab63..565ab43fa6b4 100644
--- a/arch/x86/platform/uv/uv_nmi.c
+++ b/arch/x86/platform/uv/uv_nmi.c
@@ -18,6 +18,7 @@
 #include <linux/sched/debug.h>
 #include <linux/slab.h>
 #include <linux/string.h>
+#include <linux/string_choices.h>
 #include <linux/clocksource.h>
 
 #include <asm/apic.h>
@@ -340,7 +341,7 @@ static void uv_nmi_setup_hubless_intr(void)
 		uv_pch_intr_now_enabled ? GPIROUTNMI : 0);
 
 	nmi_debug("UV:NMI: GPP_D_0 interrupt %s\n",
-		uv_pch_intr_now_enabled ? "enabled" : "disabled");
+		str_enabled_disabled(uv_pch_intr_now_enabled));
 }
 
 static struct init_nmi {
-- 
2.51.1


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

end of thread, other threads:[~2026-06-02 23:12 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-05-04 18:19 [PATCH RESEND] x86/platform/uv: use str_enabled_disabled in uv_nmi_setup_hubless_intr Thorsten Blum
2026-06-02 23:12 ` [tip: x86/cleanups] x86/platform/uv: Use str_enabled_disabled() in uv_nmi_setup_hubless_intr() tip-bot2 for Thorsten Blum
  -- strict thread matches above, loose matches on Subject: below --
2025-11-22 11:53 [PATCH RESEND] x86/platform/uv: Use str_enabled_disabled in uv_nmi_setup_hubless_intr Thorsten Blum

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

Powered by JetHome