diff options
author | Tao Ma <tao.ma@oracle.com> | 2009-08-18 05:41:57 +0200 |
---|---|---|
committer | Joel Becker <joel.becker@oracle.com> | 2009-09-23 05:09:39 +0200 |
commit | 1061f9c1c9f81ed88b5d268a95d8e3ace80da63a (patch) | |
tree | de43d1c1122ade36f079f0381712bc0f06556ac5 /fs/ocfs2/extent_map.c | |
parent | ocfs2: handle file attributes issue for reflink. (diff) | |
download | linux-1061f9c1c9f81ed88b5d268a95d8e3ace80da63a.tar.xz linux-1061f9c1c9f81ed88b5d268a95d8e3ace80da63a.zip |
ocfs2: Return extent flags for xattr value tree.
With the new refcount tree, xattr value can also be refcounted
among multiple files. So return the appropriate extent flags
so that CoW can used it later.
Signed-off-by: Tao Ma <tao.ma@oracle.com>
Diffstat (limited to 'fs/ocfs2/extent_map.c')
-rw-r--r-- | fs/ocfs2/extent_map.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/fs/ocfs2/extent_map.c b/fs/ocfs2/extent_map.c index 40b51056bb32..843db64e9d4a 100644 --- a/fs/ocfs2/extent_map.c +++ b/fs/ocfs2/extent_map.c @@ -541,7 +541,8 @@ static void ocfs2_relative_extent_offsets(struct super_block *sb, int ocfs2_xattr_get_clusters(struct inode *inode, u32 v_cluster, u32 *p_cluster, u32 *num_clusters, - struct ocfs2_extent_list *el) + struct ocfs2_extent_list *el, + unsigned int *extent_flags) { int ret = 0, i; struct buffer_head *eb_bh = NULL; @@ -593,6 +594,9 @@ int ocfs2_xattr_get_clusters(struct inode *inode, u32 v_cluster, *p_cluster = *p_cluster + coff; if (num_clusters) *num_clusters = ocfs2_rec_clusters(el, rec) - coff; + + if (extent_flags) + *extent_flags = rec->e_flags; } out: if (eb_bh) |