mirror of
https://github.com/apache/nuttx.git
synced 2026-05-25 01:39:44 +08:00
bt_uart: Don't call rxdrain in the successful path
because the physical uart bus may receive the next packet asynchronously Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
committed by
Alin Jerpelea
parent
ca5d8d8660
commit
1d8397a36d
@@ -255,14 +255,6 @@ static void btuart_rxwork(FAR void *arg)
|
||||
|
||||
wlinfo("Full packet received\n");
|
||||
|
||||
/* Drain any un-read bytes from the Rx buffer */
|
||||
|
||||
nread = lower->rxdrain(lower);
|
||||
if (nread > 0)
|
||||
{
|
||||
wlwarn("WARNING: Discarded %ld bytes\n", (long)nread);
|
||||
}
|
||||
|
||||
/* Pass buffer to the stack */
|
||||
|
||||
BT_DUMP("Received", buf->data, buf->len);
|
||||
|
||||
Reference in New Issue
Block a user