]> git.baikalelectronics.ru Git - kernel.git/commit
x86/mm: Validate memory when changing the C-bit
authorBrijesh Singh <brijesh.singh@amd.com>
Thu, 24 Feb 2022 16:56:01 +0000 (10:56 -0600)
committerBorislav Petkov <bp@suse.de>
Wed, 6 Apr 2022 11:24:53 +0000 (13:24 +0200)
commit411fd968c6805b8f2b6e77938fd0c51fdce9d154
tree2c72a1701916d2288f5703f123a0f83c2761bc8f
parent0fc661d3aac2c05d254d05f96ff72573ae5718b1
x86/mm: Validate memory when changing the C-bit

Add the needed functionality to change pages state from shared
to private and vice-versa using the Page State Change VMGEXIT as
documented in the GHCB spec.

Signed-off-by: Brijesh Singh <brijesh.singh@amd.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Link: https://lore.kernel.org/r/20220307213356.2797205-22-brijesh.singh@amd.com
arch/x86/include/asm/sev-common.h
arch/x86/include/asm/sev.h
arch/x86/include/uapi/asm/svm.h
arch/x86/kernel/sev.c
arch/x86/mm/mem_encrypt_amd.c