aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_ialloc.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/xfs_ialloc.h')
-rw-r--r--fs/xfs/xfs_ialloc.h31
1 files changed, 23 insertions, 8 deletions
diff --git a/fs/xfs/xfs_ialloc.h b/fs/xfs/xfs_ialloc.h
index 4e30ec1d13bc..50f558a4e0a8 100644
--- a/fs/xfs/xfs_ialloc.h
+++ b/fs/xfs/xfs_ialloc.h
@@ -20,6 +20,7 @@
20 20
21struct xfs_buf; 21struct xfs_buf;
22struct xfs_dinode; 22struct xfs_dinode;
23struct xfs_imap;
23struct xfs_mount; 24struct xfs_mount;
24struct xfs_trans; 25struct xfs_trans;
25 26
@@ -56,7 +57,6 @@ static inline int xfs_ialloc_find_free(xfs_inofree_t *fp)
56} 57}
57 58
58 59
59#ifdef __KERNEL__
60/* 60/*
61 * Allocate an inode on disk. 61 * Allocate an inode on disk.
62 * Mode is used to tell whether the new inode will need space, and whether 62 * Mode is used to tell whether the new inode will need space, and whether
@@ -105,17 +105,14 @@ xfs_difree(
105 xfs_ino_t *first_ino); /* first inode in deleted cluster */ 105 xfs_ino_t *first_ino); /* first inode in deleted cluster */
106 106
107/* 107/*
108 * Return the location of the inode in bno/len/off, 108 * Return the location of the inode in imap, for mapping it into a buffer.
109 * for mapping it into a buffer.
110 */ 109 */
111int 110int
112xfs_dilocate( 111xfs_imap(
113 struct xfs_mount *mp, /* file system mount structure */ 112 struct xfs_mount *mp, /* file system mount structure */
114 struct xfs_trans *tp, /* transaction pointer */ 113 struct xfs_trans *tp, /* transaction pointer */
115 xfs_ino_t ino, /* inode to locate */ 114 xfs_ino_t ino, /* inode to locate */
116 xfs_fsblock_t *bno, /* output: block containing inode */ 115 struct xfs_imap *imap, /* location map structure */
117 int *len, /* output: num blocks in cluster*/
118 int *off, /* output: index in block of inode */
119 uint flags); /* flags for inode btree lookup */ 116 uint flags); /* flags for inode btree lookup */
120 117
121/* 118/*
@@ -154,6 +151,24 @@ xfs_ialloc_pagi_init(
154 struct xfs_trans *tp, /* transaction pointer */ 151 struct xfs_trans *tp, /* transaction pointer */
155 xfs_agnumber_t agno); /* allocation group number */ 152 xfs_agnumber_t agno); /* allocation group number */
156 153
157#endif /* __KERNEL__ */ 154/*
155 * Lookup the first record greater than or equal to ino
156 * in the btree given by cur.
157 */
158int xfs_inobt_lookup_ge(struct xfs_btree_cur *cur, xfs_agino_t ino,
159 __int32_t fcnt, xfs_inofree_t free, int *stat);
160
161/*
162 * Lookup the first record less than or equal to ino
163 * in the btree given by cur.
164 */
165int xfs_inobt_lookup_le(struct xfs_btree_cur *cur, xfs_agino_t ino,
166 __int32_t fcnt, xfs_inofree_t free, int *stat);
167
168/*
169 * Get the data from the pointed-to record.
170 */
171extern int xfs_inobt_get_rec(struct xfs_btree_cur *cur, xfs_agino_t *ino,
172 __int32_t *fcnt, xfs_inofree_t *free, int *stat);
158 173
159#endif /* __XFS_IALLOC_H__ */ 174#endif /* __XFS_IALLOC_H__ */