-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mpfs_serial.c: Add RX flowcontrol #290
Conversation
I didn't understand this... so if the rx buffer is full ( 1 queued ? ), we disable rx interrupt and start loosing data? What is the issue this PR fixes? |
DP-10022. nuttx/drivers/serial/serial_io.c Line 149 in 85fe8fc
Looping for a while also RX FIFO of UART goes overrun condition. |
Got it, thanks! |
struct up_dev_s *priv = (struct up_dev_s *)dev->priv; | ||
bool ret = false; | ||
|
||
if (nbuffered == 0 || upper == false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there some bug in upper layers, or what is the reason for buffer empty check (nbuffered == 0)?
Just out of curiosity, it is fine to have it there
Please upstream the same patch to apache/nuttx before merging to our master, if possible! |
Disable RX interrupts and clear the fifo in case of full RX buffer. Enable RX interrupts in case of empty buffer.
9cf31aa
to
e895918
Compare
This is very basic functionality what we have here as we don't have RTS / CTS Flow Control in Saluki.
Disable RX interrupts and clear the FIFO in case of full RX buffer. Enable RX interrupts in case of empty buffer.