STM32F7: serial: do not stop processing input in SW flow-control mode
This commit is contained in:
parent
e9a8dc7c6e
commit
4c99a6aeec
@ -2224,6 +2224,22 @@ static bool up_rxflowcontrol(struct uart_dev_s *dev,
|
||||
/* Assert/de-assert nRTS set it high resume/stop sending */
|
||||
|
||||
stm32_gpiowrite(priv->rts_gpio, upper);
|
||||
|
||||
if (upper)
|
||||
{
|
||||
/* With heavy Rx traffic, RXNE might be set and data pending.
|
||||
* Returning 'true' in such case would cause RXNE left unhandled
|
||||
* and causing interrupt storm. Sending end might be also be slow
|
||||
* to react on nRTS, and returning 'true' here would prevent
|
||||
* processing that data.
|
||||
*
|
||||
* Therefore, return 'false' so input data is still being processed
|
||||
* until sending end reacts on nRTS signal and stops sending more.
|
||||
*/
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
return upper;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user