/* Early init I2C for prepare read the clk through I2C.  */
void i2c_early_init_f(void)
/* Early init I2C for prepare read the clk through I2C.  */
void i2c_early_init_f(void)
{
	ulong base = mxc_i2c_buses[I2C_EARLY_INIT_INDEX].base;
	bool quirk = mxc_i2c_buses[I2C_EARLY_INIT_INDEX].driver_data
					& I2C_QUIRK_FLAG ? true : false;
	int reg_shift = quirk ? VF610_I2C_REGSHIFT : IMX_I2C_REGSHIFT;
	writeb(I2C_IFDR_DIV_CONSERVATIVE, base + (IFDR << reg_shift));
	writeb(I2CR_IDIS, base + (I2CR << reg_shift));
	writeb(0, base + (I2SR << reg_shift));
	writeb(I2CR_IEN, base + (I2CR << reg_shift));
}