Lines Matching refs:msgs

212 	struct i2c_msg *msgs = dev->msgs;  in i2c_dw_xfer_init()  local
220 if (msgs[dev->msg_write_idx].flags & I2C_M_TEN) { in i2c_dw_xfer_init()
239 msgs[dev->msg_write_idx].addr | ic_tar); in i2c_dw_xfer_init()
284 static int amd_i2c_dw_xfer_quirk(struct i2c_adapter *adap, struct i2c_msg *msgs, int num_msgs) in amd_i2c_dw_xfer_quirk() argument
299 dev->msgs = msgs; in amd_i2c_dw_xfer_quirk()
306 tx_buf = msgs[msg_wrt_idx].buf; in amd_i2c_dw_xfer_quirk()
307 buf_len = msgs[msg_wrt_idx].len; in amd_i2c_dw_xfer_quirk()
309 if (!(msgs[msg_wrt_idx].flags & I2C_M_RD)) in amd_i2c_dw_xfer_quirk()
320 if (msgs[msg_wrt_idx].flags & I2C_M_RD) { in amd_i2c_dw_xfer_quirk()
366 struct i2c_msg *msgs = dev->msgs; in i2c_dw_xfer_msg() local
369 u32 addr = msgs[dev->msg_write_idx].addr; in i2c_dw_xfer_msg()
378 u32 flags = msgs[dev->msg_write_idx].flags; in i2c_dw_xfer_msg()
385 if (msgs[dev->msg_write_idx].addr != addr) { in i2c_dw_xfer_msg()
394 buf = msgs[dev->msg_write_idx].buf; in i2c_dw_xfer_msg()
395 buf_len = msgs[dev->msg_write_idx].len; in i2c_dw_xfer_msg()
437 if (msgs[dev->msg_write_idx].flags & I2C_M_RD) { in i2c_dw_xfer_msg()
486 struct i2c_msg *msgs = dev->msgs; in i2c_dw_recv_len() local
487 u32 flags = msgs[dev->msg_read_idx].flags; in i2c_dw_recv_len()
495 msgs[dev->msg_read_idx].len = len; in i2c_dw_recv_len()
496 msgs[dev->msg_read_idx].flags &= ~I2C_M_RECV_LEN; in i2c_dw_recv_len()
504 struct i2c_msg *msgs = dev->msgs; in i2c_dw_read() local
511 if (!(msgs[dev->msg_read_idx].flags & I2C_M_RD)) in i2c_dw_read()
515 len = msgs[dev->msg_read_idx].len; in i2c_dw_read()
516 buf = msgs[dev->msg_read_idx].buf; in i2c_dw_read()
525 u32 flags = msgs[dev->msg_read_idx].flags; in i2c_dw_read()
551 i2c_dw_xfer(struct i2c_adapter *adap, struct i2c_msg msgs[], int num) in i2c_dw_xfer() argument
566 ret = amd_i2c_dw_xfer_quirk(adap, msgs, num); in i2c_dw_xfer()
571 dev->msgs = msgs; in i2c_dw_xfer()