From: Erez Zadok Date: Sun, 24 Nov 2013 17:34:17 +0000 (-0500) Subject: Uniofs: port to 3.5 X-Git-Url: https://git.fsl.cs.sunysb.edu/?a=commitdiff_plain;h=becc7ba98b975897bfa0a130b7e50c8519916a66;p=unionfs-3.7.y.git Uniofs: port to 3.5 Signed-off-by: Erez Zadok --- diff --git a/fs/unionfs/file.c b/fs/unionfs/file.c index f583c8fc5a2..8a04063930e 100644 --- a/fs/unionfs/file.c +++ b/fs/unionfs/file.c @@ -156,8 +156,9 @@ static int unionfs_mmap(struct file *file, struct vm_area_struct *vma) goto out; } saved_vm_ops = vma->vm_ops; - err = do_munmap(current->mm, vma->vm_start, - vma->vm_end - vma->vm_start); + up_write(¤t->mm->mmap_sem); /* VFS already holds sema... */ + err = vm_munmap(vma->vm_start, vma->vm_end - vma->vm_start); + down_write(¤t->mm->mmap_sem); if (err) { printk(KERN_ERR "unionfs: do_munmap failed %d\n", err); goto out; diff --git a/fs/unionfs/super.c b/fs/unionfs/super.c index b99f14d1c74..53d289b19c3 100644 --- a/fs/unionfs/super.c +++ b/fs/unionfs/super.c @@ -835,7 +835,7 @@ static void unionfs_evict_inode(struct inode *inode) struct unionfs_dir_state *rdstate; truncate_inode_pages(&inode->i_data, 0); - end_writeback(inode); + clear_inode(inode); list_for_each_safe(pos, n, &UNIONFS_I(inode)->readdircache) { rdstate = list_entry(pos, struct unionfs_dir_state, cache);