Added an abort on overflow error.

git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@14972 27425a3e-05d8-49a3-a47f-9c15f0e5edd8
This commit is contained in:
Giovanni Di Sirio 2021-10-31 06:02:45 +00:00
parent a72d0f8186
commit 17e08c7939
1 changed files with 6 additions and 1 deletions

View File

@ -354,7 +354,12 @@ static void spi_lld_serve_interrupt(SPIDriver *spip) {
spip->spi->IFCR = sr;
if ((sr & SPI_SR_OVR) != 0U) {
/* TODO: fault notification.*/
/* Aborting the transfer.*/
spi_lld_stop_abort(spip);
/* Reporting the failure.*/
__spi_isr_error_code(spip, HAL_RET_HW_FAILURE);
}
}