[XFS] Cleanup a missed porting conversion, and freezing.

SGI-PV: 953338
SGI-Modid: xfs-linux-melb:xfs-kern:26109a

Signed-off-by: Nathan Scott <nathans@sgi.com>
This commit is contained in:
Nathan Scott
2006-06-09 17:11:55 +10:00
parent 8285fb58e7
commit 34327e1384
4 changed files with 11 additions and 19 deletions

View File

@@ -236,11 +236,8 @@ xfs_trans_alloc(
xfs_mount_t *mp,
uint type)
{
fs_check_frozen(XFS_MTOVFS(mp), SB_FREEZE_TRANS);
atomic_inc(&mp->m_active_trans);
return (_xfs_trans_alloc(mp, type));
vfs_wait_for_freeze(XFS_MTOVFS(mp), SB_FREEZE_TRANS);
return _xfs_trans_alloc(mp, type);
}
xfs_trans_t *
@@ -250,12 +247,9 @@ _xfs_trans_alloc(
{
xfs_trans_t *tp;
ASSERT(xfs_trans_zone != NULL);
tp = kmem_zone_zalloc(xfs_trans_zone, KM_SLEEP);
atomic_inc(&mp->m_active_trans);
/*
* Initialize the transaction structure.
*/
tp = kmem_zone_zalloc(xfs_trans_zone, KM_SLEEP);
tp->t_magic = XFS_TRANS_MAGIC;
tp->t_type = type;
tp->t_mountp = mp;
@@ -263,8 +257,7 @@ _xfs_trans_alloc(
tp->t_busy_free = XFS_LBC_NUM_SLOTS;
XFS_LIC_INIT(&(tp->t_items));
XFS_LBC_INIT(&(tp->t_busy));
return (tp);
return tp;
}
/*