Whamcloud - gitweb
LU-7981 llite: take trunc_sem only at vvp layer
[fs/lustre-release.git] / lustre / llite / llite_mmap.c
index 7d7177c..aea44c7 100644 (file)
@@ -206,17 +206,11 @@ static int ll_page_mkwrite0(struct vm_area_struct *vma, struct page *vmpage,
 
        set = cfs_block_sigsinv(sigmask(SIGKILL) | sigmask(SIGTERM));
 
-       /* we grab lli_trunc_sem to exclude truncate case.
-        * Otherwise, we could add dirty pages into osc cache
-        * while truncate is on-going. */
        inode = vvp_object_inode(io->ci_obj);
        lli = ll_i2info(inode);
-       down_read(&lli->lli_trunc_sem);
 
        result = cl_io_loop(env, io);
 
-       up_read(&lli->lli_trunc_sem);
-
        cfs_restore_sigs(set);
 
         if (result == 0) {