diff options
author | David Chinner <dgc@sgi.com> | 2007-06-18 02:50:48 -0400 |
---|---|---|
committer | Tim Shimmin <tes@chook.melbourne.sgi.com> | 2007-07-14 01:35:58 -0400 |
commit | 516b2e7c2661615ba5d5ad9fb584f068363502d3 (patch) | |
tree | 984aed9e4dd27cb2acb547dd587525b5e4bf53d9 /fs/xfs/linux-2.6/xfs_vfs.h | |
parent | 957d0ebed04239b734552c7da3fae9094b6f090c (diff) |
[XFS] Fix remount,readonly path to flush everything correctly.
The remount readonly path can fail to writeback properly because we still
have active transactions after calling xfs_quiesce_fs(). Further
investigation shows that this path is broken in the same ways that the xfs
freeze path was broken so fix it the same way.
SGI-PV: 964464
SGI-Modid: xfs-linux-melb:xfs-kern:28869a
Signed-off-by: David Chinner <dgc@sgi.com>
Signed-off-by: Christoph Hellwig <hch@infradead.org>
Signed-off-by: Tim Shimmin <tes@sgi.com>
Diffstat (limited to 'fs/xfs/linux-2.6/xfs_vfs.h')
-rw-r--r-- | fs/xfs/linux-2.6/xfs_vfs.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/fs/xfs/linux-2.6/xfs_vfs.h b/fs/xfs/linux-2.6/xfs_vfs.h index cb7b0d62fb96..dca3481aaafa 100644 --- a/fs/xfs/linux-2.6/xfs_vfs.h +++ b/fs/xfs/linux-2.6/xfs_vfs.h | |||
@@ -94,6 +94,20 @@ typedef enum { | |||
94 | #define SYNC_IOWAIT 0x0100 /* wait for all I/O to complete */ | 94 | #define SYNC_IOWAIT 0x0100 /* wait for all I/O to complete */ |
95 | #define SYNC_SUPER 0x0200 /* flush superblock to disk */ | 95 | #define SYNC_SUPER 0x0200 /* flush superblock to disk */ |
96 | 96 | ||
97 | /* | ||
98 | * When remounting a filesystem read-only or freezing the filesystem, | ||
99 | * we have two phases to execute. This first phase is syncing the data | ||
100 | * before we quiesce the fielsystem, and the second is flushing all the | ||
101 | * inodes out after we've waited for all the transactions created by | ||
102 | * the first phase to complete. The second phase uses SYNC_INODE_QUIESCE | ||
103 | * to ensure that the inodes are written to their location on disk | ||
104 | * rather than just existing in transactions in the log. This means | ||
105 | * after a quiesce there is no log replay required to write the inodes | ||
106 | * to disk (this is the main difference between a sync and a quiesce). | ||
107 | */ | ||
108 | #define SYNC_DATA_QUIESCE (SYNC_DELWRI|SYNC_FSDATA|SYNC_WAIT|SYNC_IOWAIT) | ||
109 | #define SYNC_INODE_QUIESCE (SYNC_REMOUNT|SYNC_ATTR|SYNC_WAIT) | ||
110 | |||
97 | #define SHUTDOWN_META_IO_ERROR 0x0001 /* write attempt to metadata failed */ | 111 | #define SHUTDOWN_META_IO_ERROR 0x0001 /* write attempt to metadata failed */ |
98 | #define SHUTDOWN_LOG_IO_ERROR 0x0002 /* write attempt to the log failed */ | 112 | #define SHUTDOWN_LOG_IO_ERROR 0x0002 /* write attempt to the log failed */ |
99 | #define SHUTDOWN_FORCE_UMOUNT 0x0004 /* shutdown from a forced unmount */ | 113 | #define SHUTDOWN_FORCE_UMOUNT 0x0004 /* shutdown from a forced unmount */ |