fs/ext3/super.c | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletion(-) --- linux-2.4.20/fs/ext3/super.c~ext3-unmount_sync 2003-04-08 23:35:44.000000000 -0600 +++ linux-2.4.20-braam/fs/ext3/super.c 2003-04-08 23:35:44.000000000 -0600 @@ -1612,7 +1612,12 @@ void ext3_write_super (struct super_bloc sb->s_dirt = 0; target = log_start_commit(EXT3_SB(sb)->s_journal, NULL); - if (do_sync_supers) { + /* + * Tricky --- if we are unmounting, the write really does need + * to be synchronous. We can detect that by looking for NULL in + * sb->s_root. + */ + if (do_sync_supers || !sb->s_root) { unlock_super(sb); log_wait_commit(EXT3_SB(sb)->s_journal, target); lock_super(sb); _