Revert "drivers: spi: fix the update of spi_context tx & rx length"
This reverts commit 4a486ce51b
.
This change was totally wrong.
Signed-off-by: Declan Snyder <declan.snyder@nxp.com>
This commit is contained in:
parent
c0f17f98ea
commit
2c75ad0db3
1 changed files with 2 additions and 2 deletions
|
@ -496,7 +496,7 @@ void spi_context_update_tx(struct spi_context *ctx, uint8_t dfs, uint32_t len)
|
|||
return;
|
||||
}
|
||||
|
||||
ctx->tx_len -= len * dfs;
|
||||
ctx->tx_len -= len;
|
||||
if (!ctx->tx_len) {
|
||||
/* Current buffer is done. Get the next one to be processed. */
|
||||
++ctx->current_tx;
|
||||
|
@ -555,7 +555,7 @@ void spi_context_update_rx(struct spi_context *ctx, uint8_t dfs, uint32_t len)
|
|||
return;
|
||||
}
|
||||
|
||||
ctx->rx_len -= len * dfs;
|
||||
ctx->rx_len -= len;
|
||||
if (!ctx->rx_len) {
|
||||
/* Current buffer is done. Get the next one to be processed. */
|
||||
++ctx->current_rx;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue