/* param base SPI peripheral base address. param handle Pointer to the spi_master_handle_t structure which stores the transfer state.  */
void SPI_MasterTransferAbort(SPI_Type *base, spi_master_handle_t *handle)
/* param base SPI peripheral base address. param handle Pointer to the spi_master_handle_t structure which stores the transfer state.  */
void SPI_MasterTransferAbort(SPI_Type *base, spi_master_handle_t *handle)
{
    assert(NULL != handle);
    base->FIFOINTENSET &= ~(SPI_FIFOINTENSET_TXLVL_MASK | SPI_FIFOINTENSET_RXLVL_MASK);
    base->FIFOCFG |= SPI_FIFOCFG_EMPTYTX_MASK | SPI_FIFOCFG_EMPTYRX_MASK;
    handle->state            = (uint32_t)kStatus_SPI_Idle;
    handle->txRemainingBytes = 0U;
    handle->rxRemainingBytes = 0U;
}