Home | History | Annotate | Download | only in ext2fs

Lines Matching refs:bitmap

34 	ext2fs_generic_bitmap	bitmap;
39 &bitmap);
43 bitmap->magic = EXT2_ET_MAGIC_GENERIC_BITMAP;
44 bitmap->fs = NULL;
45 bitmap->start = start;
46 bitmap->end = end;
47 bitmap->real_end = real_end;
48 bitmap->base_error_code = EXT2_ET_BAD_GENERIC_MARK;
50 retval = ext2fs_get_mem(strlen(descr)+1, &bitmap->description);
52 ext2fs_free_mem(&bitmap);
55 strcpy(bitmap->description, descr);
57 bitmap->description = 0;
59 size = (size_t) (((bitmap->real_end - bitmap->start) / 8) + 1);
60 retval = ext2fs_get_mem(size, &bitmap->bitmap);
62 ext2fs_free_mem(&bitmap->description);
63 ext2fs_free_mem(&bitmap);
68 memcpy(bitmap->bitmap, init_map, size);
70 memset(bitmap->bitmap, 0, size);
71 *ret = bitmap;
91 src->description, src->bitmap, &new_map);
109 ext2fs_set_bit(j, map->bitmap);
118 ext2fs_inode_bitmap bitmap;
131 descr, &bitmap);
135 bitmap->magic = EXT2_ET_MAGIC_INODE_BITMAP;
136 bitmap->fs = fs;
137 bitmap->base_error_code = EXT2_ET_BAD_INODE_MARK;
139 *ret = bitmap;
147 ext2fs_block_bitmap bitmap;
161 descr, &bitmap);
165 bitmap->magic = EXT2_ET_MAGIC_BLOCK_BITMAP;
166 bitmap->fs = fs;
167 bitmap->base_error_code = EXT2_ET_BAD_BLOCK_MARK;
169 *ret = bitmap;
173 errcode_t ext2fs_fudge_inode_bitmap_end(ext2fs_inode_bitmap bitmap,
176 EXT2_CHECK_MAGIC(bitmap, EXT2_ET_MAGIC_INODE_BITMAP);
178 if (end > bitmap->real_end)
181 *oend = bitmap->end;
182 bitmap->end = end;
186 errcode_t ext2fs_fudge_block_bitmap_end(ext2fs_block_bitmap bitmap,
189 EXT2_CHECK_MAGIC(bitmap, EXT2_ET_MAGIC_BLOCK_BITMAP);
191 if (end > bitmap->real_end)
194 *oend = bitmap->end;
195 bitmap->end = end;
199 void ext2fs_clear_inode_bitmap(ext2fs_inode_bitmap bitmap)
201 if (!bitmap || (bitmap->magic != EXT2_ET_MAGIC_INODE_BITMAP))
204 memset(bitmap->bitmap, 0,
205 (size_t) (((bitmap->real_end - bitmap->start) / 8) + 1));
208 void ext2fs_clear_block_bitmap(ext2fs_block_bitmap bitmap)
210 if (!bitmap || (bitmap->magic != EXT2_ET_MAGIC_BLOCK_BITMAP))
213 memset(bitmap->bitmap, 0,
214 (size_t) (((bitmap->real_end - bitmap->start) / 8) + 1));