Lines Matching defs:state
220 struct xgbe_i2c_op_state *state = &pdata->i2c.op_state;
226 while (tx_slots && state->tx_len) {
227 if (state->op->cmd == XGBE_I2C_CMD_READ)
230 cmd = *state->tx_buf++;
232 if (state->tx_len == 1)
238 state->tx_len--;
242 if (!state->tx_len)
248 struct xgbe_i2c_op_state *state = &pdata->i2c.op_state;
252 if (state->op->cmd != XGBE_I2C_CMD_READ)
256 while (rx_slots && state->rx_len) {
257 *state->rx_buf++ = XI2C_IOREAD(pdata, IC_DATA_CMD);
258 state->rx_len--;
266 struct xgbe_i2c_op_state *state = &pdata->i2c.op_state;
269 state->tx_abort_source = XI2C_IOREAD(pdata, IC_TX_ABRT_SOURCE);
280 struct xgbe_i2c_op_state *state = &pdata->i2c.op_state;
295 state->tx_abort_source, state->op->target);
299 state->ret = -EIO;
311 if (state->ret || XI2C_GET_BITS(isr, IC_RAW_INTR_STAT, STOP_DET))
379 struct xgbe_i2c_op_state *state = &pdata->i2c.op_state;
394 memset(state, 0, sizeof(*state));
395 state->op = op;
396 state->tx_len = op->len;
397 state->tx_buf = op->buf;
398 state->rx_len = op->len;
399 state->rx_buf = op->buf;
419 ret = state->ret;
421 if (state->tx_abort_source & IC_TX_ABRT_7B_ADDR_NOACK)
423 else if (state->tx_abort_source & IC_TX_ABRT_ARB_LOST)