-
Nickolai Zeldovich authored
When an ext3 partition is mounted and then quickly unmounted, the journal thread never gets around to checking the JFS_UNMOUNT flag (it immediately goes into a loop waiting for a new sequence number), causing the umount process to hang in journal_kill_thread(). The problem can be easily reproduced by roughly the following steps: dd if=/dev/zero of=/tmp/qf bs=1024k count=10 yes | mke2fs -j /tmp/qf losetup /dev/loop0 /tmp/qf mkdir /mnt/qf mount -t ext3 /dev/loop0 /mnt/qf ; umount /mnt/qf The patch below moves the check for JFS_UNMOUNT to the beginning of the journal thread loop, thereby preventing this race condition. Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
89141e47