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:
Declan Snyder 2025-06-04 12:36:48 -05:00 committed by Anas Nashif
commit 2c75ad0db3

View file

@ -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;