mm: use new helper functions around the i_mmap_mutex
[linux-2.6-block.git] / mm / filemap_xip.c
index d8d9fe3f685c00c7e7f1430ca924850d89713b07..bad746bde4a2fd44968db699865692d610c0286c 100644 (file)
@@ -182,7 +182,7 @@ __xip_unmap (struct address_space * mapping,
                return;
 
 retry:
-       mutex_lock(&mapping->i_mmap_mutex);
+       i_mmap_lock_write(mapping);
        vma_interval_tree_foreach(vma, &mapping->i_mmap, pgoff, pgoff) {
                mm = vma->vm_mm;
                address = vma->vm_start +
@@ -202,7 +202,7 @@ retry:
                        page_cache_release(page);
                }
        }
-       mutex_unlock(&mapping->i_mmap_mutex);
+       i_mmap_unlock_write(mapping);
 
        if (locked) {
                mutex_unlock(&xip_sparse_mutex);