summaryrefslogtreecommitdiff
path: root/fs/xfs
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@infradead.org>2009-09-09 18:19:02 -0500
committerAlex Elder <aelder@sgi.com>2009-09-09 18:19:02 -0500
commit4734d401d43c6469d568caf223d37aa0fc1bf4dc (patch)
treed73cbfd3537a5681ab5523e320a55b240b2fdd72 /fs/xfs
parent988abe4075e5748d9f7c79d9dfffa0cf5291611b (diff)
downloadlinux-3.10-4734d401d43c6469d568caf223d37aa0fc1bf4dc.tar.gz
linux-3.10-4734d401d43c6469d568caf223d37aa0fc1bf4dc.tar.bz2
linux-3.10-4734d401d43c6469d568caf223d37aa0fc1bf4dc.zip
xfs: use correct log reservation when handling ENOSPC in xfs_create
We added the ENOSPC handling patch in xfs_create just after it got mered with xfs_mkdir. Change the log reservation to the variable for either the create or mkdir value so it does the right thing if get here for creating a directory. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Alex Elder <aelder@sgi.com>
Diffstat (limited to 'fs/xfs')
-rw-r--r--fs/xfs/xfs_vnodeops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c
index 03d3100559a..a434f287962 100644
--- a/fs/xfs/xfs_vnodeops.c
+++ b/fs/xfs/xfs_vnodeops.c
@@ -1471,8 +1471,8 @@ xfs_create(
if (error == ENOSPC) {
/* flush outstanding delalloc blocks and retry */
xfs_flush_inodes(dp);
- error = xfs_trans_reserve(tp, resblks, XFS_CREATE_LOG_RES(mp), 0,
- XFS_TRANS_PERM_LOG_RES, XFS_CREATE_LOG_COUNT);
+ error = xfs_trans_reserve(tp, resblks, log_res, 0,
+ XFS_TRANS_PERM_LOG_RES, log_count);
}
if (error == ENOSPC) {
/* No space at all so try a "no-allocation" reservation */