[RFC PATCH 33/67] KVM: Export kvm_is_reserved_pfn() for use by TDX

From: isaku . yamahata
Date: Mon Nov 16 2020 - 13:32:11 EST


From: Sean Christopherson <sean.j.christopherson@xxxxxxxxx>

TDX will use kvm_is_reserved_pfn() to prevent installing a reserved PFN
int SEPT. Or rather, to prevent such an attempt, as reserved PFNs are
not covered by TDMRs.

Signed-off-by: Sean Christopherson <sean.j.christopherson@xxxxxxxxx>
---
virt/kvm/kvm_main.c | 1 +
1 file changed, 1 insertion(+)

diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index aa5f27753756..a60dcf682f33 100644
--- a/virt/kvm/kvm_main.c
+++ b/virt/kvm/kvm_main.c
@@ -185,6 +185,7 @@ bool kvm_is_reserved_pfn(kvm_pfn_t pfn)

return true;
}
+EXPORT_SYMBOL_GPL(kvm_is_reserved_pfn);

bool kvm_is_transparent_hugepage(kvm_pfn_t pfn)
{
--
2.17.1