Lines Matching refs:blk
107 errcode_t ext2fs_u32_list_add(ext2_u32_list bb, __u32 blk)
130 if ((bb->num != 0) && (bb->list[i] == blk))
132 if ((bb->num == 0) || (bb->list[i] < blk)) {
133 bb->list[bb->num++] = blk;
139 if (bb->list[i] == blk)
141 if (bb->list[i] > blk) {
148 bb->list[j] = blk;
153 errcode_t ext2fs_badblocks_list_add(ext2_badblocks_list bb, blk_t blk)
155 return ext2fs_u32_list_add((ext2_u32_list) bb, (__u32) blk);
162 int ext2fs_u32_list_find(ext2_u32_list bb, __u32 blk)
174 if (blk == bb->list[low])
176 if (blk == bb->list[high])
183 if (blk == bb->list[mid])
185 if (blk < bb->list[mid])
197 int ext2fs_u32_list_test(ext2_u32_list bb, __u32 blk)
199 if (ext2fs_u32_list_find(bb, blk) < 0)
205 int ext2fs_badblocks_list_test(ext2_badblocks_list bb, blk_t blk)
207 return ext2fs_u32_list_test((ext2_u32_list) bb, (__u32) blk);
214 int ext2fs_u32_list_del(ext2_u32_list bb, __u32 blk)
221 remloc = ext2fs_u32_list_find(bb, blk);
231 void ext2fs_badblocks_list_del(ext2_u32_list bb, __u32 blk)
233 ext2fs_u32_list_del(bb, blk);
263 int ext2fs_u32_list_iterate(ext2_u32_iterate iter, __u32 *blk)
276 *blk = bb->list[iter->ptr++];
279 *blk = 0;
283 int ext2fs_badblocks_list_iterate(ext2_badblocks_iterate iter, blk_t *blk)
286 (__u32 *) blk);