Thread (123 messages) 123 messages, 8 authors, 2021-09-15

Re: [PATCH Part1 v5 11/38] x86/compressed: Add helper for validating pages in the decompression stage

From: Borislav Petkov <bp@alien8.de>
Date: 2021-08-23 14:16:30
Also in: kvm, linux-coco, linux-mm, lkml, platform-driver-x86

On Fri, Aug 20, 2021 at 10:19:06AM -0500, Brijesh Singh wrote:
quoted hunk ↗ jump to hunk
diff --git a/arch/x86/include/asm/sev-common.h b/arch/x86/include/asm/sev-common.h
index d426c30ae7b4..1cd8ce838af8 100644
--- a/arch/x86/include/asm/sev-common.h
+++ b/arch/x86/include/asm/sev-common.h
@@ -57,6 +57,26 @@
 #define GHCB_MSR_AP_RESET_HOLD_REQ	0x006
 #define GHCB_MSR_AP_RESET_HOLD_RESP	0x007
 
+/* SNP Page State Change */
Let's make it very clear here that those cmd numbers below are actually
part of the protocol and not randomly chosen:

/*
 * ...
 *
 * 0x014 – SNP Page State Change Request
 *
 * GHCBData[55:52] – Page operation:
 *   0x0001 – Page assignment, Private
 *   0x0002 – Page assignment, Shared
 */
+enum psc_op {
+	SNP_PAGE_STATE_PRIVATE = 1,
+	SNP_PAGE_STATE_SHARED,
+};
+
-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help