/* This is a helper function which initializes various UBIFS constants after the master node has been read. It also checks various UBIFS parameters and makes sure they are all right.  */
static void init_constants_master(struct ubifs_info *c)
/* This is a helper function which initializes various UBIFS constants after the master node has been read. It also checks various UBIFS parameters and makes sure they are all right.  */
static void init_constants_master(struct ubifs_info *c)
{
	long long tmp64;
	c->min_idx_lebs = ubifs_calc_min_idx_lebs(c);
	tmp64 = c->main_lebs - 1 - 1 - MIN_INDEX_LEBS - c->jhead_cnt + 1;
	tmp64 *= (long long)c->leb_size - c->leb_overhead;
	tmp64 = ubifs_reported_space(c, tmp64);
	c->block_cnt = tmp64 >> UBIFS_BLOCK_SHIFT;
}