Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
serial:ifx6x60:Prevent data transfer when IFX6x60 port is shutdown
This patch is to implement following 2 places to avoid potential error when IFX6x60 port shutdown: 1) Clear Flag IFX_SPI_STATE_IO_AVAILABLE to disable data transfer when Modem port is shutdown; 2) Clear Flag IFX_SPI_STATE_IO_IN_PROGRESS and IFX_SPI_STATE_IO_READY when reopen port. This is because last port shutdown may happen when SPI/DMA transfer is in progress, if the last data transfer is not completed(for example due to modem reset), the Flag IFX_SPI_STATE_IO_IN_PROGRESS will be set forever, so when IFX port is activated again, IFX_SPI_STATE_IO_IN_PROGRESS will prevent transferring data forever. And if don't clear IFX_SPI_STATE_IO_READY, it may cause one more SPI frame transferring in spit there is not data need to be transfer. cc: liu chuansheng <[email protected]> cc: Chen Jun <[email protected]> Signed-off-by: channing <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
- Loading branch information