All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86/mm: Consolidate SME comments and use break
@ 2026-06-09 11:30 Thorsten Blum
  2026-06-09 14:23 ` Dave Hansen
  0 siblings, 1 reply; 4+ messages in thread
From: Thorsten Blum @ 2026-06-09 11:30 UTC (permalink / raw)
  To: Dave Hansen, Andy Lutomirski, Peter Zijlstra, Thomas Gleixner,
	Ingo Molnar, Borislav Petkov, x86, H. Peter Anvin
  Cc: Thorsten Blum, linux-kernel

Combine the two SME comments and use break instead of return to exit the
switch consistently with the other cases.

Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 arch/x86/mm/mem_encrypt.c | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/arch/x86/mm/mem_encrypt.c b/arch/x86/mm/mem_encrypt.c
index 95bae74fdab2..c6bab01a5db8 100644
--- a/arch/x86/mm/mem_encrypt.c
+++ b/arch/x86/mm/mem_encrypt.c
@@ -53,14 +53,13 @@ static void print_mem_encrypt_feature_info(void)
 	case CC_VENDOR_AMD:
 		pr_cont("AMD");
 
-		/* Secure Memory Encryption */
-		if (cc_platform_has(CC_ATTR_HOST_MEM_ENCRYPT)) {
 		/*
-		 * SME is mutually exclusive with any of the SEV
-		 * features below.
-		*/
+		 * Secure Memory Encryption is mutually exclusive with
+		 * any of the SEV features below.
+		 */
+		if (cc_platform_has(CC_ATTR_HOST_MEM_ENCRYPT)) {
 			pr_cont(" SME\n");
-			return;
+			break;
 		}
 
 		/* Secure Encrypted Virtualization */

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

end of thread, other threads:[~2026-06-09 16:26 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-09 11:30 [PATCH] x86/mm: Consolidate SME comments and use break Thorsten Blum
2026-06-09 14:23 ` Dave Hansen
2026-06-09 15:32   ` Thorsten Blum
2026-06-09 16:26     ` Dave Hansen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.