]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: Do fsync log replay when mount -o ro, except when on readonly media
authorChris Mason <chris.mason@oracle.com>
Wed, 19 Nov 2008 20:13:35 +0000 (15:13 -0500)
committerChris Mason <chris.mason@oracle.com>
Wed, 19 Nov 2008 20:13:35 +0000 (15:13 -0500)
commit0a5dbb20801152a18984217668756357828f6e5f
tree8c6cf2661f1f15869acdbbf7096bce2e19a1c1e1
parent1a37f74844942a80c0d5615dd35bf7ce7ca68658
Btrfs: Do fsync log replay when mount -o ro, except when on readonly media

fsync log replay can change the filesystem, so it cannot be delayed until
mount -o rw,remount, and it can't be forgotten entirely.  So, this patch
changes btrfs to do with reiserfs, ext3 and xfs do, which is to do the
log replay even when mounted readonly.

On a readonly device if log replay is required, the mount is aborted.

Getting all of this right had required fixing up some of the error
handling in open_ctree.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/disk-io.c