summaryrefslogtreecommitdiffstats
path: root/fs/bfs
diff options
context:
space:
mode:
Diffstat (limited to 'fs/bfs')
-rw-r--r--fs/bfs/inode.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/bfs/inode.c b/fs/bfs/inode.c
index cc4062d12ca2..4cf3d269e271 100644
--- a/fs/bfs/inode.c
+++ b/fs/bfs/inode.c
@@ -30,6 +30,7 @@ MODULE_LICENSE("GPL");
#define dprintf(x...)
#endif
+static void bfs_write_super(struct super_block *s);
void dump_imap(const char *prefix, struct super_block *s);
struct inode *bfs_iget(struct super_block *sb, unsigned long ino)
@@ -216,6 +217,9 @@ static void bfs_put_super(struct super_block *s)
if (!info)
return;
+ if (s->s_dirt)
+ bfs_write_super(s);
+
brelse(info->si_sbh);
mutex_destroy(&info->bfs_lock);
kfree(info->si_imap);