lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <174636841731.22196.14042198424404966355.tip-bot2@tip-bot2>
Date: Sun, 04 May 2025 14:20:17 -0000
From: "tip-bot2 for Ard Biesheuvel" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Ard Biesheuvel <ardb@...nel.org>, Ingo Molnar <mingo@...nel.org>,
 Arnd Bergmann <arnd@...db.de>, David Woodhouse <dwmw@...zon.co.uk>,
 Dionna Amalie Glaze <dionnaglaze@...gle.com>,
 "H. Peter Anvin" <hpa@...or.com>, Kees Cook <keescook@...omium.org>,
 Kevin Loughlin <kevinloughlin@...gle.com>, Len Brown <len.brown@...el.com>,
 Linus Torvalds <torvalds@...ux-foundation.org>,
 "Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
 Tom Lendacky <thomas.lendacky@....com>, linux-efi@...r.kernel.org,
 x86@...nel.org, linux-kernel@...r.kernel.org
Subject: [tip: x86/boot] x86/sev: Make sev_snp_enabled() a static function

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

Commit-ID:     fae89bbfdd9d692e3cb6eace89f4994177731b8c
Gitweb:        https://git.kernel.org/tip/fae89bbfdd9d692e3cb6eace89f4994177731b8c
Author:        Ard Biesheuvel <ardb@...nel.org>
AuthorDate:    Sun, 04 May 2025 11:52:34 +02:00
Committer:     Ingo Molnar <mingo@...nel.org>
CommitterDate: Sun, 04 May 2025 15:53:06 +02:00

x86/sev: Make sev_snp_enabled() a static function

sev_snp_enabled() is no longer used outside of the source file that
defines it, so make it static and drop the extern declarations.

Signed-off-by: Ard Biesheuvel <ardb@...nel.org>
Signed-off-by: Ingo Molnar <mingo@...nel.org>
Cc: Arnd Bergmann <arnd@...db.de>
Cc: David Woodhouse <dwmw@...zon.co.uk>
Cc: Dionna Amalie Glaze <dionnaglaze@...gle.com>
Cc: H. Peter Anvin <hpa@...or.com>
Cc: Kees Cook <keescook@...omium.org>
Cc: Kevin Loughlin <kevinloughlin@...gle.com>
Cc: Len Brown <len.brown@...el.com>
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Rafael J. Wysocki <rafael.j.wysocki@...el.com>
Cc: Tom Lendacky <thomas.lendacky@....com>
Cc: linux-efi@...r.kernel.org
Link: https://lore.kernel.org/r/20250504095230.2932860-29-ardb+git@google.com
---
 arch/x86/boot/compressed/sev.c | 2 +-
 arch/x86/boot/compressed/sev.h | 2 --
 2 files changed, 1 insertion(+), 3 deletions(-)

diff --git a/arch/x86/boot/compressed/sev.c b/arch/x86/boot/compressed/sev.c
index 2ccad0a..f4b7f17 100644
--- a/arch/x86/boot/compressed/sev.c
+++ b/arch/x86/boot/compressed/sev.c
@@ -164,7 +164,7 @@ int svsm_perform_call_protocol(struct svsm_call *call)
 	return ret;
 }
 
-bool sev_snp_enabled(void)
+static bool sev_snp_enabled(void)
 {
 	return sev_status & MSR_AMD64_SEV_SNP_ENABLED;
 }
diff --git a/arch/x86/boot/compressed/sev.h b/arch/x86/boot/compressed/sev.h
index d390038..e87af54 100644
--- a/arch/x86/boot/compressed/sev.h
+++ b/arch/x86/boot/compressed/sev.h
@@ -10,14 +10,12 @@
 
 #ifdef CONFIG_AMD_MEM_ENCRYPT
 
-bool sev_snp_enabled(void);
 void snp_accept_memory(phys_addr_t start, phys_addr_t end);
 u64 sev_get_status(void);
 bool early_is_sevsnp_guest(void);
 
 #else
 
-static inline bool sev_snp_enabled(void) { return false; }
 static inline void snp_accept_memory(phys_addr_t start, phys_addr_t end) { }
 static inline u64 sev_get_status(void) { return 0; }
 static inline bool early_is_sevsnp_guest(void) { return false; }

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ