diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-27 22:09:16 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-27 22:09:16 -0400 |
commit | 73a0e405dce7d720808536b708f7c738b413b1a2 (patch) | |
tree | 60cc93e993e89b0c83a549bd65647879ce37d9cc /fs/xfs/xfs_vnodeops.c | |
parent | 03529d9f66b7995c67ddceb8f83258df3c9915da (diff) | |
parent | 5493a0fcba8a94baa5c1d80aca21d6ae4b3b573e (diff) |
Merge git://oss.sgi.com:8090/nathans/xfs-2.6
* git://oss.sgi.com:8090/nathans/xfs-2.6:
[XFS] Fixup whitespace damage in log_write, remove final warning.
[XFS] Rework code snippets slightly to remove remaining recent-gcc
[XFS] Fix realtime subvolume expansion, a porting bug b0rked it. Coverity
[XFS] Remove a race condition where a linked inode could BUG_ON in
[XFS] Remove redundant directory checks from inode link operation.
[XFS] Remove a couple of no-longer-used macros.
[XFS] Reduce size of xfs_trans_t structure. * remove ->t_forw, ->t_back --
[XFS] remove unused behaviour lock - shrink XFS vnode as a side effect.
[XFS] * There is trivial "inode => vnode => inode" conversion, but only
[XFS] link(2) on directory is banned in VFS.
Diffstat (limited to 'fs/xfs/xfs_vnodeops.c')
-rw-r--r-- | fs/xfs/xfs_vnodeops.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/fs/xfs/xfs_vnodeops.c b/fs/xfs/xfs_vnodeops.c index 00a6b7dc24a0..23cfa5837728 100644 --- a/fs/xfs/xfs_vnodeops.c +++ b/fs/xfs/xfs_vnodeops.c | |||
@@ -2603,8 +2603,7 @@ xfs_link( | |||
2603 | vn_trace_entry(src_vp, __FUNCTION__, (inst_t *)__return_address); | 2603 | vn_trace_entry(src_vp, __FUNCTION__, (inst_t *)__return_address); |
2604 | 2604 | ||
2605 | target_namelen = VNAMELEN(dentry); | 2605 | target_namelen = VNAMELEN(dentry); |
2606 | if (VN_ISDIR(src_vp)) | 2606 | ASSERT(!VN_ISDIR(src_vp)); |
2607 | return XFS_ERROR(EPERM); | ||
2608 | 2607 | ||
2609 | sip = xfs_vtoi(src_vp); | 2608 | sip = xfs_vtoi(src_vp); |
2610 | tdp = XFS_BHVTOI(target_dir_bdp); | 2609 | tdp = XFS_BHVTOI(target_dir_bdp); |
@@ -2699,9 +2698,8 @@ xfs_link( | |||
2699 | xfs_trans_log_inode(tp, tdp, XFS_ILOG_CORE); | 2698 | xfs_trans_log_inode(tp, tdp, XFS_ILOG_CORE); |
2700 | 2699 | ||
2701 | error = xfs_bumplink(tp, sip); | 2700 | error = xfs_bumplink(tp, sip); |
2702 | if (error) { | 2701 | if (error) |
2703 | goto abort_return; | 2702 | goto abort_return; |
2704 | } | ||
2705 | 2703 | ||
2706 | /* | 2704 | /* |
2707 | * If this is a synchronous mount, make sure that the | 2705 | * If this is a synchronous mount, make sure that the |
@@ -2719,9 +2717,8 @@ xfs_link( | |||
2719 | } | 2717 | } |
2720 | 2718 | ||
2721 | error = xfs_trans_commit(tp, XFS_TRANS_RELEASE_LOG_RES, NULL); | 2719 | error = xfs_trans_commit(tp, XFS_TRANS_RELEASE_LOG_RES, NULL); |
2722 | if (error) { | 2720 | if (error) |
2723 | goto std_return; | 2721 | goto std_return; |
2724 | } | ||
2725 | 2722 | ||
2726 | /* Fall through to std_return with error = 0. */ | 2723 | /* Fall through to std_return with error = 0. */ |
2727 | std_return: | 2724 | std_return: |
@@ -2742,6 +2739,8 @@ std_return: | |||
2742 | xfs_trans_cancel(tp, cancel_flags); | 2739 | xfs_trans_cancel(tp, cancel_flags); |
2743 | goto std_return; | 2740 | goto std_return; |
2744 | } | 2741 | } |
2742 | |||
2743 | |||
2745 | /* | 2744 | /* |
2746 | * xfs_mkdir | 2745 | * xfs_mkdir |
2747 | * | 2746 | * |