diff options
-rw-r--r-- | fs/gfs2/super.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c index 79cac705769..a8d90f2f576 100644 --- a/fs/gfs2/super.c +++ b/fs/gfs2/super.c @@ -1545,6 +1545,11 @@ static void gfs2_evict_inode(struct inode *inode) out_truncate: gfs2_log_flush(sdp, ip->i_gl); + if (test_bit(GLF_DIRTY, &ip->i_gl->gl_flags)) { + struct address_space *metamapping = gfs2_glock2aspace(ip->i_gl); + filemap_fdatawrite(metamapping); + filemap_fdatawait(metamapping); + } write_inode_now(inode, 1); gfs2_ail_flush(ip->i_gl, 0); |