diff options
author | Tao Ma <tao.ma@oracle.com> | 2009-08-17 23:24:49 -0400 |
---|---|---|
committer | Joel Becker <joel.becker@oracle.com> | 2009-09-22 23:09:33 -0400 |
commit | 1823cb0b9fe5e6d48017ee3f92428f69c0235d87 (patch) | |
tree | 461e5d6cc255c400acac69dd968fae935a9c073f /fs/ocfs2/alloc.h | |
parent | e73a819db9c2d6c4065b7cab7374709b6939e8f1 (diff) |
ocfs2: Add support of decrementing refcount for delete.
Given a physical cpos and length, decrement the refcount
in the tree. If the refcount for any portion of the extent goes
to zero, that portion is queued for freeing.
Signed-off-by: Tao Ma <tao.ma@oracle.com>
Diffstat (limited to 'fs/ocfs2/alloc.h')
-rw-r--r-- | fs/ocfs2/alloc.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/ocfs2/alloc.h b/fs/ocfs2/alloc.h index 3f4348923b73..0610ba148ea0 100644 --- a/fs/ocfs2/alloc.h +++ b/fs/ocfs2/alloc.h | |||
@@ -202,6 +202,9 @@ static inline void ocfs2_init_dealloc_ctxt(struct ocfs2_cached_dealloc_ctxt *c) | |||
202 | } | 202 | } |
203 | int ocfs2_cache_cluster_dealloc(struct ocfs2_cached_dealloc_ctxt *ctxt, | 203 | int ocfs2_cache_cluster_dealloc(struct ocfs2_cached_dealloc_ctxt *ctxt, |
204 | u64 blkno, unsigned int bit); | 204 | u64 blkno, unsigned int bit); |
205 | int ocfs2_cache_block_dealloc(struct ocfs2_cached_dealloc_ctxt *ctxt, | ||
206 | int type, int slot, u64 blkno, | ||
207 | unsigned int bit); | ||
205 | static inline int ocfs2_dealloc_has_cluster(struct ocfs2_cached_dealloc_ctxt *c) | 208 | static inline int ocfs2_dealloc_has_cluster(struct ocfs2_cached_dealloc_ctxt *c) |
206 | { | 209 | { |
207 | return c->c_global_allocator != NULL; | 210 | return c->c_global_allocator != NULL; |