aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ia64
diff options
context:
space:
mode:
Diffstat (limited to 'arch/ia64')
-rw-r--r--arch/ia64/kvm/kvm-ia64.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/ia64/kvm/kvm-ia64.c b/arch/ia64/kvm/kvm-ia64.c
index bd510beb43af..d85b5d2d52d1 100644
--- a/arch/ia64/kvm/kvm-ia64.c
+++ b/arch/ia64/kvm/kvm-ia64.c
@@ -1817,10 +1817,12 @@ static int kvm_ia64_sync_dirty_log(struct kvm *kvm,
1817 n = kvm_dirty_bitmap_bytes(memslot); 1817 n = kvm_dirty_bitmap_bytes(memslot);
1818 base = memslot->base_gfn / BITS_PER_LONG; 1818 base = memslot->base_gfn / BITS_PER_LONG;
1819 1819
1820 spin_lock(&kvm->arch.dirty_log_lock);
1820 for (i = 0; i < n/sizeof(long); ++i) { 1821 for (i = 0; i < n/sizeof(long); ++i) {
1821 memslot->dirty_bitmap[i] = dirty_bitmap[base + i]; 1822 memslot->dirty_bitmap[i] = dirty_bitmap[base + i];
1822 dirty_bitmap[base + i] = 0; 1823 dirty_bitmap[base + i] = 0;
1823 } 1824 }
1825 spin_unlock(&kvm->arch.dirty_log_lock);
1824 r = 0; 1826 r = 0;
1825out: 1827out:
1826 return r; 1828 return r;
@@ -1835,7 +1837,6 @@ int kvm_vm_ioctl_get_dirty_log(struct kvm *kvm,
1835 int is_dirty = 0; 1837 int is_dirty = 0;
1836 1838
1837 mutex_lock(&kvm->slots_lock); 1839 mutex_lock(&kvm->slots_lock);
1838 spin_lock(&kvm->arch.dirty_log_lock);
1839 1840
1840 r = kvm_ia64_sync_dirty_log(kvm, log); 1841 r = kvm_ia64_sync_dirty_log(kvm, log);
1841 if (r) 1842 if (r)
@@ -1855,7 +1856,6 @@ int kvm_vm_ioctl_get_dirty_log(struct kvm *kvm,
1855 r = 0; 1856 r = 0;
1856out: 1857out:
1857 mutex_unlock(&kvm->slots_lock); 1858 mutex_unlock(&kvm->slots_lock);
1858 spin_unlock(&kvm->arch.dirty_log_lock);
1859 return r; 1859 return r;
1860} 1860}
1861 1861