aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ocfs2/alloc.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ocfs2/alloc.h')
-rw-r--r--fs/ocfs2/alloc.h23
1 files changed, 16 insertions, 7 deletions
diff --git a/fs/ocfs2/alloc.h b/fs/ocfs2/alloc.h
index a0e334f10cd1..473c8bcc62fb 100644
--- a/fs/ocfs2/alloc.h
+++ b/fs/ocfs2/alloc.h
@@ -26,28 +26,37 @@
26#ifndef OCFS2_ALLOC_H 26#ifndef OCFS2_ALLOC_H
27#define OCFS2_ALLOC_H 27#define OCFS2_ALLOC_H
28 28
29enum ocfs2_extent_tree_type {
30 OCFS2_DINODE_EXTENT = 0,
31};
32
29struct ocfs2_alloc_context; 33struct ocfs2_alloc_context;
30int ocfs2_insert_extent(struct ocfs2_super *osb, 34int ocfs2_insert_extent(struct ocfs2_super *osb,
31 handle_t *handle, 35 handle_t *handle,
32 struct inode *inode, 36 struct inode *inode,
33 struct buffer_head *fe_bh, 37 struct buffer_head *root_bh,
34 u32 cpos, 38 u32 cpos,
35 u64 start_blk, 39 u64 start_blk,
36 u32 new_clusters, 40 u32 new_clusters,
37 u8 flags, 41 u8 flags,
38 struct ocfs2_alloc_context *meta_ac); 42 struct ocfs2_alloc_context *meta_ac,
43 enum ocfs2_extent_tree_type et_type);
39struct ocfs2_cached_dealloc_ctxt; 44struct ocfs2_cached_dealloc_ctxt;
40int ocfs2_mark_extent_written(struct inode *inode, struct buffer_head *di_bh, 45int ocfs2_mark_extent_written(struct inode *inode, struct buffer_head *root_bh,
41 handle_t *handle, u32 cpos, u32 len, u32 phys, 46 handle_t *handle, u32 cpos, u32 len, u32 phys,
42 struct ocfs2_alloc_context *meta_ac, 47 struct ocfs2_alloc_context *meta_ac,
43 struct ocfs2_cached_dealloc_ctxt *dealloc); 48 struct ocfs2_cached_dealloc_ctxt *dealloc,
44int ocfs2_remove_extent(struct inode *inode, struct buffer_head *di_bh, 49 enum ocfs2_extent_tree_type et_type);
50int ocfs2_remove_extent(struct inode *inode, struct buffer_head *root_bh,
45 u32 cpos, u32 len, handle_t *handle, 51 u32 cpos, u32 len, handle_t *handle,
46 struct ocfs2_alloc_context *meta_ac, 52 struct ocfs2_alloc_context *meta_ac,
47 struct ocfs2_cached_dealloc_ctxt *dealloc); 53 struct ocfs2_cached_dealloc_ctxt *dealloc,
54 enum ocfs2_extent_tree_type et_type);
48int ocfs2_num_free_extents(struct ocfs2_super *osb, 55int ocfs2_num_free_extents(struct ocfs2_super *osb,
49 struct inode *inode, 56 struct inode *inode,
50 struct buffer_head *bh); 57 struct buffer_head *root_bh,
58 enum ocfs2_extent_tree_type et_type);
59
51/* 60/*
52 * how many new metadata chunks would an allocation need at maximum? 61 * how many new metadata chunks would an allocation need at maximum?
53 * 62 *