]> www.infradead.org Git - users/jedix/linux-maple.git/commit
x86/sev: Map only the RMP table entries instead of the full RMP range
authorTom Lendacky <thomas.lendacky@amd.com>
Mon, 2 Dec 2024 20:50:50 +0000 (14:50 -0600)
committerBorislav Petkov (AMD) <bp@alien8.de>
Sat, 14 Dec 2024 10:39:02 +0000 (11:39 +0100)
commitac517965a5a12d685f1e7a7f77e64503167f87d5
treea54f68f4512f30ff24af2ec7db371c914493ddfb
parente2f3d40df82eeb70f6c3602418bca63c54183776
x86/sev: Map only the RMP table entries instead of the full RMP range

In preparation for support of a segmented RMP table, map only the RMP
table entries. The RMP bookkeeping area is only ever accessed when
first enabling SNP and does not need to remain mapped. To accomplish
this, split the initialization of the RMP bookkeeping area and the
initialization of the RMP entry area. The RMP bookkeeping area will be
mapped only while it is being initialized.

Signed-off-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Nikunj A Dadhania <nikunj@amd.com>
Reviewed-by: Neeraj Upadhyay <Neeraj.Upadhyay@amd.com>
Reviewed-by: Ashish Kalra <ashish.kalra@amd.com>
Link: https://lore.kernel.org/r/22f179998d319834f49c13a8c01187fbf0fd308d.1733172653.git.thomas.lendacky@amd.com
arch/x86/virt/svm/sev.c