summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaolo Bonzini2019-08-05 11:11:08 +0200
committerPaolo Bonzini2019-08-09 16:49:58 +0200
commit8f946da73aaa1c3f609bd14d1193f39afa6830c7 (patch)
treea512aa350aad7c2475b2cfd583cfd4fdcb87d058
parentx86: kvm: remove useless calls to kvm_para_available (diff)
downloadkernel-qcow2-linux-8f946da73aaa1c3f609bd14d1193f39afa6830c7.tar.gz
kernel-qcow2-linux-8f946da73aaa1c3f609bd14d1193f39afa6830c7.tar.xz
kernel-qcow2-linux-8f946da73aaa1c3f609bd14d1193f39afa6830c7.zip
kvm: remove unnecessary PageReserved check
The same check is already done in kvm_is_reserved_pfn. Reviewed-by: Sean Christopherson <sean.j.christopherson@intel.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
-rw-r--r--virt/kvm/kvm_main.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/virt/kvm/kvm_main.c b/virt/kvm/kvm_main.c
index 4feceaa03fb1..c6a91b044d8d 100644
--- a/virt/kvm/kvm_main.c
+++ b/virt/kvm/kvm_main.c
@@ -1855,8 +1855,7 @@ void kvm_set_pfn_dirty(kvm_pfn_t pfn)
if (!kvm_is_reserved_pfn(pfn)) {
struct page *page = pfn_to_page(pfn);
- if (!PageReserved(page))
- SetPageDirty(page);
+ SetPageDirty(page);
}
}
EXPORT_SYMBOL_GPL(kvm_set_pfn_dirty);