[RFC PATCH 08/31] KVM: selftests: Make GHCB entry page size aligned

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Make GHCB entry page size aligned. Without this change
GHCB GPA registration gets incorrectly interpreted in
host as a GHCB MSR protocol request.

Signed-off-by: Neeraj Upadhyay <Neeraj.Upadhyay@xxxxxxx>
---
 tools/testing/selftests/kvm/lib/x86/sev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/testing/selftests/kvm/lib/x86/sev.c b/tools/testing/selftests/kvm/lib/x86/sev.c
index 228c446072a8..38813f60c252 100644
--- a/tools/testing/selftests/kvm/lib/x86/sev.c
+++ b/tools/testing/selftests/kvm/lib/x86/sev.c
@@ -22,7 +22,7 @@ struct ghcb_entry {
 
 	/* Host virtual address of this struct. */
 	struct ghcb_entry *hva;
-};
+} __attribute__((__aligned__(PAGE_SIZE)));
 
 struct ghcb_header {
 	struct ghcb_entry ghcbs[KVM_MAX_VCPUS];
-- 
2.34.1





[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux