drivers: spi: nrf: fix async cs deactivation
Chip Select signal must be deactivated only after transaction is finalized. In async case this means it cannot be done from `transceive` call context, as this context is left as soon as transfer is initialized. Signed-off-by: Nikodem Kastelik <nikodem.kastelik@nordicsemi.no>
This commit is contained in:
parent
77e875a0b7
commit
7080f0f83f
1 changed files with 2 additions and 2 deletions
|
@ -298,6 +298,8 @@ static void finish_transaction(const struct device *dev, int error)
|
|||
|
||||
spi_context_complete(ctx, dev, error);
|
||||
dev_data->busy = false;
|
||||
|
||||
spi_context_cs_control(&dev_data->ctx, false);
|
||||
}
|
||||
|
||||
static void transfer_next_chunk(const struct device *dev)
|
||||
|
@ -468,8 +470,6 @@ static int transceive(const struct device *dev,
|
|||
anomaly_58_workaround_clear(dev_data);
|
||||
#endif
|
||||
}
|
||||
|
||||
spi_context_cs_control(&dev_data->ctx, false);
|
||||
}
|
||||
|
||||
spi_context_release(&dev_data->ctx, error);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue