Commit b8c5e8e2 authored by Federico Vaga's avatar Federico Vaga

sw:drv:spi: fix set transfer len in hardware

Signed-off-by: Federico Vaga's avatarFederico Vaga <federico.vaga@cern.ch>
parent 413ee400
......@@ -502,6 +502,7 @@ static int spi_ocores_sw_xfer_next_init(struct spi_ocores *sp)
hz = sp->cur_xfer->speed_hz;
else
hz = sp->master->cur_msg->spi->max_speed_hz;
sp->cur_ctrl |= (sp->cur_xfer->len * 8) & SPI_OCORES_CTRL_CHAR_LEN;
sp->cur_divider = 1 + (sp->clock_hz / (hz * 2));
sp->cur_tx_buf = sp->cur_xfer->tx_buf;
sp->cur_tx_len = sp->cur_xfer->len;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment