mirror of
https://github.com/apache/nuttx.git
synced 2026-10-19 20:58:54 +00:00
kinetis/serial: Do not xmit when no chars to xmit
When there are no data in the TX buffer, we can avoid call to the uart_xmitchars. Signed-off-by: Jiri Vlasak <jvlasak@elektroline.cz>
This commit is contained in:
parent
fd3e524c0f
commit
444073e370
1 changed files with 1 additions and 1 deletions
|
|
@ -1288,7 +1288,7 @@ static int up_interrupts(int irq, void *context, void *arg)
|
|||
* the TX data register.
|
||||
*/
|
||||
|
||||
if ((s1 & UART_S1_TDRE) != 0)
|
||||
if ((s1 & UART_S1_TDRE) != 0 && dev->xmit.head != dev->xmit.tail)
|
||||
#endif
|
||||
{
|
||||
/* Process outgoing bytes */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue