Skip to contentSkip to conversation

FAILED: patch "[PATCH] KVM: SVM: Don't strip the C-bit from CR2 on #PF interception" failed to apply to 5.4-stable tree

PATCH [email protected] 1 participant 1 message May 12, 2021

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 5.4-stable tree.
If someone wants it applied there, or to any other stable or longterm tree, then please email the backport, including the original git commit id to <[email protected]>.

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

From 6d1b867d045699d6ce0dfa0ef35d1b87dd36db56 Mon Sep 17 00:00:00 2001
From: Sean Christopherson <[email protected]>
Date: Thu, 4 Mar 2021 17:10:56 -0800
Subject: [PATCH] KVM: SVM: Don't strip the C-bit from CR2 on #PF interception

Don't strip the C-bit from the faulting address on an intercepted #PF, the address is a virtual address, not a physical address.

Fixes 0ede79e13224 ("KVM: SVM: Clear C-bit from the page fault address")
Cc Brijesh Singh <[email protected]>
Cc Tom Lendacky <[email protected]>

Message-Id: <[email protected]>

arch/x86/kvm/svm/svm.c +1 -1
index 58a45bb139f8..cc45ea16c0d7 100644
@@ -1898,7 +1898,7 @@ static void svm_set_dr7(struct kvm_vcpu *vcpu, unsigned long value)
 
 static int pf_interception(struct vcpu_svm *svm)
 {
-	u64 fault_address = __sme_clr(svm->vmcb->control.exit_info_2);
+	u64 fault_address = svm->vmcb->control.exit_info_2;
 	u64 error_code = svm->vmcb->control.exit_info_1;
 
 	return kvm_handle_page_fault(&svm->vcpu, error_code, fault_address,