Lines Matching refs:req
46 mxc_i2c_req_t req; member
112 mxc_i2c_req_t *req = &data->req; in max32_msg_start() local
115 req->i2c = i2c; in max32_msg_start()
116 req->addr = i2c_addr; in max32_msg_start()
128 req->rx_buf = (unsigned char *)buf; in max32_msg_start()
129 req->rx_len = buf_len; in max32_msg_start()
130 req->tx_buf = NULL; in max32_msg_start()
131 req->tx_len = 0; in max32_msg_start()
134 req->tx_buf = (unsigned char *)buf; in max32_msg_start()
135 req->tx_len = buf_len; in max32_msg_start()
136 req->rx_buf = NULL; in max32_msg_start()
137 req->rx_len = 0; in max32_msg_start()
147 Wrap_MXC_I2C_SetRxCount(i2c, req->rx_len); in max32_msg_start()
154 if (req->tx_len) { in max32_msg_start()
155 data->written = MXC_I2C_WriteTXFIFO(i2c, req->tx_buf, 1); in max32_msg_start()
185 mxc_i2c_req_t *req = &data->req; in i2c_max32_isr_controller() local
207 if (written < req->tx_len) { in i2c_max32_isr_controller()
209 } else if (readb < req->rx_len) { in i2c_max32_isr_controller()
215 if (req->tx_len && in i2c_max32_isr_controller()
217 if (written < req->tx_len) { in i2c_max32_isr_controller()
218 written += MXC_I2C_WriteTXFIFO(i2c, &req->tx_buf[written], in i2c_max32_isr_controller()
219 req->tx_len - written); in i2c_max32_isr_controller()
239 readb += MXC_I2C_ReadRXFIFO(i2c, &req->rx_buf[readb], req->rx_len - readb); in i2c_max32_isr_controller()
240 if (readb == req->rx_len) { in i2c_max32_isr_controller()
256 Wrap_MXC_I2C_SetRxCount(i2c, req->rx_len - readb); in i2c_max32_isr_controller()
258 i2c->fifo = (req->addr << 1) | 0x1; in i2c_max32_isr_controller()