Lines Matching refs:reg_shift
186 int reg_shift = quirk ? VF610_I2C_REGSHIFT : IMX_I2C_REGSHIFT; in bus_i2c_set_bus_speed() local
192 writeb(idx, base + (IFDR << reg_shift)); in bus_i2c_set_bus_speed()
195 writeb(I2CR_IDIS, base + (I2CR << reg_shift)); in bus_i2c_set_bus_speed()
196 writeb(0, base + (I2SR << reg_shift)); in bus_i2c_set_bus_speed()
209 int reg_shift = quirk ? VF610_I2C_REGSHIFT : IMX_I2C_REGSHIFT; in wait_for_sr_state() local
213 sr = readb(base + (I2SR << reg_shift)); in wait_for_sr_state()
217 (I2SR << reg_shift)); in wait_for_sr_state()
220 (I2SR << reg_shift)); in wait_for_sr_state()
222 __func__, sr, readb(base + (I2CR << reg_shift)), in wait_for_sr_state()
234 sr, readb(base + (I2CR << reg_shift)), state); in wait_for_sr_state()
241 int reg_shift = i2c_bus->driver_data & I2C_QUIRK_FLAG ? in tx_byte() local
245 writeb(I2SR_IIF_CLEAR, base + (I2SR << reg_shift)); in tx_byte()
246 writeb(byte, base + (I2DR << reg_shift)); in tx_byte()
271 int reg_shift = i2c_bus->driver_data & I2C_QUIRK_FLAG ? in i2c_imx_stop() local
274 unsigned int temp = readb(base + (I2CR << reg_shift)); in i2c_imx_stop()
277 writeb(temp, base + (I2CR << reg_shift)); in i2c_imx_stop()
294 int reg_shift = quirk ? VF610_I2C_REGSHIFT : IMX_I2C_REGSHIFT; in i2c_init_transfer_() local
301 ret = readb(base + (I2CR << reg_shift)) & I2CR_IDIS; in i2c_init_transfer_()
303 ret = !(readb(base + (I2CR << reg_shift)) & I2CR_IEN); in i2c_init_transfer_()
306 writeb(I2CR_IEN, base + (I2CR << reg_shift)); in i2c_init_transfer_()
311 if (readb(base + (IADR << reg_shift)) == (chip << 1)) in i2c_init_transfer_()
312 writeb((chip << 1) ^ 2, base + (IADR << reg_shift)); in i2c_init_transfer_()
313 writeb(I2SR_IIF_CLEAR, base + (I2SR << reg_shift)); in i2c_init_transfer_()
319 temp = readb(base + (I2CR << reg_shift)); in i2c_init_transfer_()
321 writeb(temp, base + (I2CR << reg_shift)); in i2c_init_transfer_()
328 writeb(temp, base + (I2CR << reg_shift)); in i2c_init_transfer_()
498 int reg_shift = quirk ? VF610_I2C_REGSHIFT : IMX_I2C_REGSHIFT; in i2c_early_init_f() local
501 writeb(I2C_IFDR_DIV_CONSERVATIVE, base + (IFDR << reg_shift)); in i2c_early_init_f()
503 writeb(I2CR_IDIS, base + (I2CR << reg_shift)); in i2c_early_init_f()
504 writeb(0, base + (I2SR << reg_shift)); in i2c_early_init_f()
506 writeb(I2CR_IEN, base + (I2CR << reg_shift)); in i2c_early_init_f()
514 int reg_shift = i2c_bus->driver_data & I2C_QUIRK_FLAG ? in i2c_init_transfer() local
532 writeb(I2CR_IDIS, i2c_bus->base + (I2CR << reg_shift)); in i2c_init_transfer()
576 int reg_shift = i2c_bus->driver_data & I2C_QUIRK_FLAG ? in i2c_read_data() local
583 temp = readb(base + (I2CR << reg_shift)); in i2c_read_data()
587 writeb(temp, base + (I2CR << reg_shift)); in i2c_read_data()
588 writeb(I2SR_IIF_CLEAR, base + (I2SR << reg_shift)); in i2c_read_data()
590 readb(base + (I2DR << reg_shift)); in i2c_read_data()
611 temp = readb(base + (I2CR << reg_shift)); in i2c_read_data()
613 writeb(temp, base + (I2CR << reg_shift)); in i2c_read_data()
621 temp = readb(base + (I2CR << reg_shift)); in i2c_read_data()
623 writeb(temp, base + (I2CR << reg_shift)); in i2c_read_data()
626 writeb(I2SR_IIF_CLEAR, base + (I2SR << reg_shift)); in i2c_read_data()
627 buf[i] = readb(base + (I2DR << reg_shift)); in i2c_read_data()
677 int reg_shift = i2c_bus->driver_data & I2C_QUIRK_FLAG ? in bus_i2c_read() local
686 temp = readb(base + (I2CR << reg_shift)); in bus_i2c_read()
688 writeb(temp, base + (I2CR << reg_shift)); in bus_i2c_read()
999 int reg_shift = i2c_bus->driver_data & I2C_QUIRK_FLAG ?
1024 ret = readb(base + (I2CR << reg_shift));
1026 writeb(ret, base + (I2CR << reg_shift));