Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 47861
b: refs/heads/master
c: 3c0dc77
h: refs/heads/master
i:
  47859: 603484a
v: v3
  • Loading branch information
David Chinner authored and Tim Shimmin committed Feb 10, 2007
1 parent 0283449 commit 341b7db
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: f7c99b6fc7b3791cd24e0763cd4967d744c164a3
refs/heads/master: 3c0dc77b42cee99c71e913765073888620d442fa
2 changes: 1 addition & 1 deletion trunk/fs/xfs/linux-2.6/xfs_super.c
Original file line number Diff line number Diff line change
Expand Up @@ -667,7 +667,7 @@ xfs_fs_sync_super(
* occur here so don't bother flushing the buftarg (i.e
* SYNC_QUIESCE) because it'll just get dirty again.
*/
flags = SYNC_FSDATA | SYNC_DELWRI | SYNC_WAIT | SYNC_DIO_WAIT;
flags = SYNC_FSDATA | SYNC_DELWRI | SYNC_WAIT | SYNC_IOWAIT;
} else
flags = SYNC_FSDATA | (wait ? SYNC_WAIT : 0);

Expand Down
3 changes: 1 addition & 2 deletions trunk/fs/xfs/linux-2.6/xfs_vfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,7 @@ typedef enum {
#define SYNC_FSDATA 0x0020 /* flush fs data (e.g. superblocks) */
#define SYNC_REFCACHE 0x0040 /* prune some of the nfs ref cache */
#define SYNC_REMOUNT 0x0080 /* remount readonly, no dummy LRs */
#define SYNC_QUIESCE 0x0100 /* quiesce fileystem for a snapshot */
#define SYNC_DIO_WAIT 0x0200 /* wait for direct I/O to complete */
#define SYNC_IOWAIT 0x0100 /* wait for all I/O to complete */

#define SHUTDOWN_META_IO_ERROR 0x0001 /* write attempt to metadata failed */
#define SHUTDOWN_LOG_IO_ERROR 0x0002 /* write attempt to the log failed */
Expand Down
17 changes: 9 additions & 8 deletions trunk/fs/xfs/xfs_vfsops.c
Original file line number Diff line number Diff line change
Expand Up @@ -872,10 +872,10 @@ xfs_statvfs(
* this by simply making sure the log gets flushed
* if SYNC_BDFLUSH is set, and by actually writing it
* out otherwise.
* SYNC_DIO_WAIT - The caller wants us to wait for all direct I/Os
* as well to ensure all data I/O completes before we
* return. Forms the drain side of the write barrier needed
* to safely quiesce the filesystem.
* SYNC_IOWAIT - The caller wants us to wait for all data I/O to complete
* before we return (including direct I/O). Forms the drain
* side of the write barrier needed to safely quiesce the
* filesystem.
*
*/
/*ARGSUSED*/
Expand Down Expand Up @@ -1174,10 +1174,11 @@ xfs_sync_inodes(

}
/*
* When freezing, we need to wait ensure direct I/O is complete
* as well to ensure all data modification is complete here
* When freezing, we need to wait ensure all I/O (including direct
* I/O) is complete to ensure no further data modification can take
* place after this point
*/
if (flags & SYNC_DIO_WAIT)
if (flags & SYNC_IOWAIT)
vn_iowait(vp);

if (flags & SYNC_BDFLUSH) {
Expand Down Expand Up @@ -1975,7 +1976,7 @@ xfs_freeze(
/* flush inodes and push all remaining buffers out to disk */
xfs_quiesce_fs(mp);

BUG_ON(atomic_read(&mp->m_active_trans) > 0);
ASSERT_ALWAYS(atomic_read(&mp->m_active_trans) == 0);

/* Push the superblock and write an unmount record */
xfs_log_unmount_write(mp);
Expand Down

0 comments on commit 341b7db

Please sign in to comment.