aboutsummaryrefslogtreecommitdiffstats
path: root/virt/kvm/iommu.c
diff options
context:
space:
mode:
Diffstat (limited to 'virt/kvm/iommu.c')
-rw-r--r--virt/kvm/iommu.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/virt/kvm/iommu.c b/virt/kvm/iommu.c
index 11692b9e8830..d2f06be63354 100644
--- a/virt/kvm/iommu.c
+++ b/virt/kvm/iommu.c
@@ -127,7 +127,7 @@ static int kvm_iommu_map_memslots(struct kvm *kvm)
127 int i, r = 0; 127 int i, r = 0;
128 struct kvm_memslots *slots; 128 struct kvm_memslots *slots;
129 129
130 slots = rcu_dereference(kvm->memslots); 130 slots = kvm_memslots(kvm);
131 131
132 for (i = 0; i < slots->nmemslots; i++) { 132 for (i = 0; i < slots->nmemslots; i++) {
133 r = kvm_iommu_map_pages(kvm, &slots->memslots[i]); 133 r = kvm_iommu_map_pages(kvm, &slots->memslots[i]);
@@ -286,7 +286,7 @@ static int kvm_iommu_unmap_memslots(struct kvm *kvm)
286 int i; 286 int i;
287 struct kvm_memslots *slots; 287 struct kvm_memslots *slots;
288 288
289 slots = rcu_dereference(kvm->memslots); 289 slots = kvm_memslots(kvm);
290 290
291 for (i = 0; i < slots->nmemslots; i++) { 291 for (i = 0; i < slots->nmemslots; i++) {
292 kvm_iommu_put_pages(kvm, slots->memslots[i].base_gfn, 292 kvm_iommu_put_pages(kvm, slots->memslots[i].base_gfn,