Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
873ee1c
virt: sev-guest: Replace dev_dbg() with pr_debug()
nikunjad Jul 31, 2024
1a7d6bd
virt: sev-guest: Rename local guest message variables
nikunjad Jul 31, 2024
9e8162c
virt: sev-guest: Fix user-visible strings
nikunjad Jul 31, 2024
80ee220
virt: sev-guest: Ensure the SNP guest messages do not exceed a page
nikunjad Jul 31, 2024
b7a1ca9
virt: sev-guest: Use AES GCM crypto library
nikunjad Oct 9, 2024
9e6b9cf
x86/sev: Handle failures from snp_init()
nikunjad Oct 9, 2024
72b7eaa
x86/sev: Cache the secrets page address
nikunjad Oct 9, 2024
6c36baf
virt: sev-guest: Consolidate SNP guest messaging parameters to a struct
nikunjad Oct 9, 2024
1191723
virt: sev-guest: Reduce the scope of SNP command mutex
nikunjad Oct 9, 2024
9fd4bb1
virt: sev-guest: Carve out SNP message context structure
nikunjad Oct 9, 2024
2e6bfc9
virt: sev-guest: Remove is_vmpck_empty() helper
nikunjad Jan 6, 2025
3ce8779
virt: sev-guest: Replace GFP_KERNEL_ACCOUNT with GFP_KERNEL
nikunjad Jan 6, 2025
3d3fd96
x86/sev: Carve out and export SNP guest messaging init routines
nikunjad Jan 6, 2025
45c0781
x86/sev: Relocate SNP guest messaging routines to common code
nikunjad Jan 6, 2025
ae3684b
x86/sev: Add Secure TSC support for SNP guests
nikunjad Jan 6, 2025
a0d9359
x86/sev: Cleanup vc_handle_msr()
bp3tk0v Nov 6, 2024
b114ab9
x86/sev: Change TSC MSR behavior for Secure TSC enabled guests
nikunjad Jan 6, 2025
59ce59f
x86/sev: Prevent GUEST_TSC_FREQ MSR interception for Secure TSC enabl…
nikunjad Jan 6, 2025
6548596
x86/sev: Prevent RDTSC/RDTSCP interception for Secure TSC enabled guests
nikunjad Jan 6, 2025
65f6f28
x86/sev: Mark the TSC in a secure TSC guest as reliable
nikunjad Jan 6, 2025
282b07b
x86/tsc: Init the TSC for Secure TSC guests
nikunjad Jan 6, 2025
0118f7f
x86/sev: Add the Secure TSC feature for SNP guests
nikunjad Jan 6, 2025
81a08b9
KVM: SVM: Macrofy SEV=n versions of sev_xxx_guest()
sean-jc Nov 27, 2024
4e7927c
x86/cpufeatures: Add SNP Secure TSC
nikunjad Mar 17, 2025
b19db68
KVM: SVM: Add missing member in SNP_LAUNCH_START command structure
nikunjad Mar 17, 2025
03f77e9
KVM: SVM: Add GUEST_TSC_FREQ MSR for Secure TSC enabled guests
nikunjad Mar 17, 2025
9839fe6
KVM: SVM: Enable Secure TSC for SNP guests
ketanch Aug 30, 2022
de7b288
KVM: x86: Push down setting vcpu.arch.user_set_tsc
yamahata Oct 12, 2024
572ace0
KVM: SVM: Don't allow tsc_offset, tsc_scaling_ratio to change
yamahata Oct 12, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions arch/x86/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -1552,6 +1552,7 @@ config AMD_MEM_ENCRYPT
select ARCH_HAS_CC_PLATFORM
select X86_MEM_ENCRYPT
select UNACCEPTED_MEMORY
select CRYPTO_LIB_AESGCM
help
Say yes to enable support for the encryption of system memory.
This requires an AMD processor that supports Secure Memory
Expand Down
3 changes: 2 additions & 1 deletion arch/x86/boot/compressed/sev.c
Original file line number Diff line number Diff line change
Expand Up @@ -401,7 +401,8 @@ void do_boot_stage2_vc(struct pt_regs *regs, unsigned long exit_code)
* by the guest kernel. As and when a new feature is implemented in the
* guest kernel, a corresponding bit should be added to the mask.
*/
#define SNP_FEATURES_PRESENT MSR_AMD64_SNP_DEBUG_SWAP
#define SNP_FEATURES_PRESENT (MSR_AMD64_SNP_DEBUG_SWAP | \
MSR_AMD64_SNP_SECURE_TSC)

u64 snp_get_unsupported_features(u64 status)
{
Expand Down
4 changes: 3 additions & 1 deletion arch/x86/coco/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ static __maybe_unused __always_inline bool amd_cc_platform_vtom(enum cc_attr att
* up under SME the trampoline area cannot be encrypted, whereas under SEV
* the trampoline area must be encrypted.
*/

static bool noinstr amd_cc_platform_has(enum cc_attr attr)
{
#ifdef CONFIG_AMD_MEM_ENCRYPT
Expand Down Expand Up @@ -97,6 +96,9 @@ static bool noinstr amd_cc_platform_has(enum cc_attr attr)
case CC_ATTR_GUEST_SEV_SNP:
return sev_status & MSR_AMD64_SEV_SNP_ENABLED;

case CC_ATTR_GUEST_SNP_SECURE_TSC:
return sev_status & MSR_AMD64_SNP_SECURE_TSC;

case CC_ATTR_HOST_SEV_SNP:
return cc_flags.host_sev_snp;

Expand Down
Loading