GFS2: Don't warn when delete inode fails on ro filesystem
authorSteven Whitehouse <swhiteho@redhat.com>
Tue, 19 May 2009 13:25:16 +0000 (14:25 +0100)
committerSteven Whitehouse <swhiteho@redhat.com>
Tue, 19 May 2009 13:25:16 +0000 (14:25 +0100)
If the filesystem is read-only, then we expect that delete inode
will fail, so there is no need to warn about it.

Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
fs/gfs2/ops_super.c

index a3c2272..2fd1dcb 100644 (file)
@@ -714,7 +714,7 @@ out_unlock:
                gfs2_glock_dq(&ip->i_iopen_gh);
        gfs2_holder_uninit(&ip->i_iopen_gh);
        gfs2_glock_dq_uninit(&gh);
-       if (error && error != GLR_TRYFAILED)
+       if (error && error != GLR_TRYFAILED && error != -EROFS)
                fs_warn(sdp, "gfs2_delete_inode: %d\n", error);
 out:
        truncate_inode_pages(&inode->i_data, 0);