drivers/serial: transmit lock should in pairs
Signed-off-by: chao an <anchao@xiaomi.com>
This commit is contained in:
parent
b048428180
commit
a53cc533c0
@ -469,6 +469,7 @@ static int uart_tcdrain(FAR uart_dev_t *dev,
|
|||||||
elapsed = clock_systime_ticks() - start;
|
elapsed = clock_systime_ticks() - start;
|
||||||
if (elapsed >= timeout)
|
if (elapsed >= timeout)
|
||||||
{
|
{
|
||||||
|
nxmutex_unlock(&dev->xmit.lock);
|
||||||
return -ETIMEDOUT;
|
return -ETIMEDOUT;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user