summaryrefslogtreecommitdiff
path: root/virt
diff options
context:
space:
mode:
authorAlex Shi <alex.shi@linaro.org>2018-03-13 12:02:10 +0800
committerAlex Shi <alex.shi@linaro.org>2018-03-13 12:02:10 +0800
commit0bdf4ea52af04501c69799babfdd0b38cbf0299e (patch)
treeab784e8eb73ed40e760075e0e111719937de3f91 /virt
parenta2b5256f1edd2d412d14ec9dceb1d28e39a794e4 (diff)
parent8b5ab55d254f36e89b1b53aeac7223d2d102483e (diff)
Merge tag 'v4.4.121' into linux-linaro-lsk-v4.4
This is the 4.4.121 stable release
Diffstat (limited to 'virt')
-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 d080f06fd8d9..b814ae6822b6 100644
--- a/virt/kvm/kvm_main.c
+++ b/virt/kvm/kvm_main.c
@@ -902,8 +902,7 @@ int __kvm_set_memory_region(struct kvm *kvm,
/* Check for overlaps */
r = -EEXIST;
kvm_for_each_memslot(slot, __kvm_memslots(kvm, as_id)) {
- if ((slot->id >= KVM_USER_MEM_SLOTS) ||
- (slot->id == id))
+ if (slot->id == id)
continue;
if (!((base_gfn + npages <= slot->base_gfn) ||
(base_gfn >= slot->base_gfn + slot->npages)))