aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs')
-rw-r--r--fs/xfs/linux-2.6/xfs_sync.c2
-rw-r--r--fs/xfs/xfs_mount.c15
-rw-r--r--fs/xfs/xfs_mount.h2
3 files changed, 7 insertions, 12 deletions
diff --git a/fs/xfs/linux-2.6/xfs_sync.c b/fs/xfs/linux-2.6/xfs_sync.c
index f54e8ee1ed62..5cc158e52d4c 100644
--- a/fs/xfs/linux-2.6/xfs_sync.c
+++ b/fs/xfs/linux-2.6/xfs_sync.c
@@ -434,7 +434,7 @@ xfs_quiesce_attr(
434 WARN_ON(atomic_read(&mp->m_active_trans) != 0); 434 WARN_ON(atomic_read(&mp->m_active_trans) != 0);
435 435
436 /* Push the superblock and write an unmount record */ 436 /* Push the superblock and write an unmount record */
437 error = xfs_log_sbcount(mp, 1); 437 error = xfs_log_sbcount(mp);
438 if (error) 438 if (error)
439 xfs_warn(mp, "xfs_attr_quiesce: failed to log sb changes. " 439 xfs_warn(mp, "xfs_attr_quiesce: failed to log sb changes. "
440 "Frozen image may not be consistent."); 440 "Frozen image may not be consistent.");
diff --git a/fs/xfs/xfs_mount.c b/fs/xfs/xfs_mount.c
index 1fe643aa0efd..7f25245da289 100644
--- a/fs/xfs/xfs_mount.c
+++ b/fs/xfs/xfs_mount.c
@@ -1521,7 +1521,7 @@ xfs_unmountfs(
1521 xfs_warn(mp, "Unable to free reserved block pool. " 1521 xfs_warn(mp, "Unable to free reserved block pool. "
1522 "Freespace may not be correct on next mount."); 1522 "Freespace may not be correct on next mount.");
1523 1523
1524 error = xfs_log_sbcount(mp, 1); 1524 error = xfs_log_sbcount(mp);
1525 if (error) 1525 if (error)
1526 xfs_warn(mp, "Unable to update superblock counters. " 1526 xfs_warn(mp, "Unable to update superblock counters. "
1527 "Freespace may not be correct on next mount."); 1527 "Freespace may not be correct on next mount.");
@@ -1557,18 +1557,14 @@ xfs_fs_writable(xfs_mount_t *mp)
1557/* 1557/*
1558 * xfs_log_sbcount 1558 * xfs_log_sbcount
1559 * 1559 *
1560 * Called either periodically to keep the on disk superblock values 1560 * Sync the superblock counters to disk.
1561 * roughly up to date or from unmount to make sure the values are
1562 * correct on a clean unmount.
1563 * 1561 *
1564 * Note this code can be called during the process of freezing, so 1562 * Note this code can be called during the process of freezing, so
1565 * we may need to use the transaction allocator which does not not 1563 * we may need to use the transaction allocator which does not
1566 * block when the transaction subsystem is in its frozen state. 1564 * block when the transaction subsystem is in its frozen state.
1567 */ 1565 */
1568int 1566int
1569xfs_log_sbcount( 1567xfs_log_sbcount(xfs_mount_t *mp)
1570 xfs_mount_t *mp,
1571 uint sync)
1572{ 1568{
1573 xfs_trans_t *tp; 1569 xfs_trans_t *tp;
1574 int error; 1570 int error;
@@ -1594,8 +1590,7 @@ xfs_log_sbcount(
1594 } 1590 }
1595 1591
1596 xfs_mod_sb(tp, XFS_SB_IFREE | XFS_SB_ICOUNT | XFS_SB_FDBLOCKS); 1592 xfs_mod_sb(tp, XFS_SB_IFREE | XFS_SB_ICOUNT | XFS_SB_FDBLOCKS);
1597 if (sync) 1593 xfs_trans_set_sync(tp);
1598 xfs_trans_set_sync(tp);
1599 error = xfs_trans_commit(tp, 0); 1594 error = xfs_trans_commit(tp, 0);
1600 return error; 1595 return error;
1601} 1596}
diff --git a/fs/xfs/xfs_mount.h b/fs/xfs/xfs_mount.h
index 3d68bb267c5f..bb24dac42a25 100644
--- a/fs/xfs/xfs_mount.h
+++ b/fs/xfs/xfs_mount.h
@@ -371,7 +371,7 @@ typedef struct xfs_mod_sb {
371 int64_t msb_delta; /* Change to make to specified field */ 371 int64_t msb_delta; /* Change to make to specified field */
372} xfs_mod_sb_t; 372} xfs_mod_sb_t;
373 373
374extern int xfs_log_sbcount(xfs_mount_t *, uint); 374extern int xfs_log_sbcount(xfs_mount_t *);
375extern __uint64_t xfs_default_resblks(xfs_mount_t *mp); 375extern __uint64_t xfs_default_resblks(xfs_mount_t *mp);
376extern int xfs_mountfs(xfs_mount_t *mp); 376extern int xfs_mountfs(xfs_mount_t *mp);
377 377