aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/inode.c
diff options
context:
space:
mode:
authorTiger Yang <tiger.yang@oracle.com>2008-08-18 05:11:00 -0400
committerMark Fasheh <mfasheh@suse.com>2008-10-13 19:57:02 -0400
commitcf1d6c763fbcb115263114302485ad17e7933d87 (patch)
tree85717dc9d20b7ac1e31b683653933f2d30099f44 /fs/ocfs2/inode.c
parentfdd77704a8b4666a32120fcd1e4a9fedaf3263d8 (diff)
ocfs2: Add extended attribute support
This patch implements storing extended attributes both in inode or a single external block. We only store EA's in-inode when blocksize > 512 or that inode block has free space for it. When an EA's value is larger than 80 bytes, we will store the value via b-tree outside inode or block. Signed-off-by: Tiger Yang <tiger.yang@oracle.com> Signed-off-by: Mark Fasheh <mfasheh@suse.com>
Diffstat (limited to 'fs/ocfs2/inode.c')
-rw-r--r--fs/ocfs2/inode.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/fs/ocfs2/inode.c b/fs/ocfs2/inode.c
index 99f012a0f207..4738dd25bb94 100644
--- a/fs/ocfs2/inode.c
+++ b/fs/ocfs2/inode.c
@@ -49,6 +49,7 @@
49#include "symlink.h" 49#include "symlink.h"
50#include "sysfile.h" 50#include "sysfile.h"
51#include "uptodate.h" 51#include "uptodate.h"
52#include "xattr.h"
52 53
53#include "buffer_head_io.h" 54#include "buffer_head_io.h"
54 55
@@ -741,6 +742,13 @@ static int ocfs2_wipe_inode(struct inode *inode,
741 goto bail_unlock_dir; 742 goto bail_unlock_dir;
742 } 743 }
743 744
745 /*Free extended attribute resources associated with this inode.*/
746 status = ocfs2_xattr_remove(inode, di_bh);
747 if (status < 0) {
748 mlog_errno(status);
749 goto bail_unlock_dir;
750 }
751
744 status = ocfs2_remove_inode(inode, di_bh, orphan_dir_inode, 752 status = ocfs2_remove_inode(inode, di_bh, orphan_dir_inode,
745 orphan_dir_bh); 753 orphan_dir_bh);
746 if (status < 0) 754 if (status < 0)