From: Jan Beulich Date: Tue, 12 Mar 2019 18:11:35 +0000 (+0000) Subject: SVM: fix build after "make nested page-fault tracing and logging consistent" X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=19a1c8529b6bcee56db5c8a5729bff2c8eb10fc8;p=people%2Fliuw%2Fxen.git SVM: fix build after "make nested page-fault tracing and logging consistent" Some compiler versions don't recognize that "mfn" can't really be used uninitialized in svm_do_nested_pgfault(). To be on the safe side, add an initializer for p2mt as well. Reported-by: Andrew Cooper Signed-off-by: Jan Beulich Reviewed-by: Boris Ostrovsky --- diff --git a/xen/arch/x86/hvm/svm/svm.c b/xen/arch/x86/hvm/svm/svm.c index fec9be3ae0..506258abdc 100644 --- a/xen/arch/x86/hvm/svm/svm.c +++ b/xen/arch/x86/hvm/svm/svm.c @@ -1762,8 +1762,8 @@ static void svm_do_nested_pgfault(struct vcpu *v, { int ret; unsigned long gfn = gpa >> PAGE_SHIFT; - mfn_t mfn; - p2m_type_t p2mt; + mfn_t mfn = INVALID_MFN; + p2m_type_t p2mt = p2m_invalid; p2m_access_t p2ma; struct p2m_domain *p2m = NULL;