ext2_gd
struct ext2_gd *b_cgd; /* cylinder group descriptor */
sizeof(struct ext2_gd)],
sblock.e2fs_bsize / sizeof(struct ext2_gd));
fs->e2fs_bsize / sizeof(struct ext2_gd));
&sblock.e2fs_gd[i* sblock.e2fs_bsize / sizeof(struct ext2_gd)],
blocks_gd = howmany(sizeof(struct ext2_gd) * ncg, bsize);
blocks_gd = howmany(sizeof(struct ext2_gd) * ncg, bsize);
target_ngdb = howmany(sizeof(struct ext2_gd) * target_ncg,
e2fs_cgsave(gd, (struct ext2_gd *)(iobuf + sblock.e2fs_bsize),
sizeof(struct ext2_gd) * sblock.e2fs_ncg);
e2fs_cgsave(gd, (struct ext2_gd *)(iobuf +
sizeof(struct ext2_gd) * sblock.e2fs_ncg);
howmany(fs->e2fs_ncg, fs->e2fs_bsize / sizeof(struct ext2_gd));
gdpb = fs->e2fs_bsize / sizeof(struct ext2_gd);
e2fs_cgload((struct ext2_gd *)fp->f_buf,
(fs->e2fs_ncg - gdpb * i) * sizeof(struct ext2_gd):
fs->e2fs_gd = alloc(sizeof(struct ext2_gd) * fs->e2fs_ncg);
sizeof(struct ext2_gd) * fp->f_fs->e2fs_ncg);
struct ext2_gd *e2fs_gd; /* group descriptors (data not byteswapped) */
#define E2FS_REV0_GD_SIZE (sizeof(struct ext2_gd) / 2) /* 32 */
ext2fs_cg_update(struct m_ext2fs *fs, int cg, struct ext2_gd *gd, int nbfree, int nifree, int ndirs, daddr_t ioff)
ext2fs_cg_get_csum(struct m_ext2fs *fs, int cg, struct ext2_gd *gd)
off = offsetof(struct ext2_gd, ext2bgd_checksum);
off = offsetof(struct ext2_gd, ext2bgd_checksum);
ext2fs_init_bb(struct m_ext2fs *fs, int cg, struct ext2_gd *gd, char *bbp)
struct ext2_gd *gd;
struct ext2_gd *, int, int, int, daddr_t);
static uint16_t ext2fs_cg_get_csum(struct m_ext2fs *, int, struct ext2_gd *);
static void ext2fs_init_bb(struct m_ext2fs *, int, struct ext2_gd *,
e2fs_cgload(const char *ondisk, struct ext2_gd *inmemory, int cg_size,
struct ext2_gd *optr = inmemory;
e2fs_cgsave(const struct ext2_gd *inmemory, char *ondisk, int cg_size,
const struct ext2_gd *iptr = inmemory;
* sizeof(struct ext2_gd), KM_SLEEP);
kmem_free(m_fs->e2fs_gd, m_fs->e2fs_ngdb * sh * sizeof(struct ext2_gd));
kmem_free(fs->e2fs_gd, fs->e2fs_ngdb * sh * sizeof(struct ext2_gd));
howmany(fs->e2fs_ncg, fs->e2fs_bsize / sizeof(struct ext2_gd));
gdpb = fs->e2fs_bsize / sizeof(struct ext2_gd);
e2fs_cgload((struct ext2_gd *)gdbuf, &fs->e2fs_gd[gdpb * i],
(fs->e2fs_ncg - gdpb * i) * sizeof(struct ext2_gd):
fs->e2fs_gd = malloc(sizeof(struct ext2_gd) * fs->e2fs_ncg);