CV-Bowen commented on code in PR #21384:
URL: https://github.com/apache/nuttx/pull/21384#discussion_r4450562942


##########
drivers/rpmsg/rpmsg_port_uart.c:
##########
@@ -538,6 +542,7 @@ static void
 rpmsg_port_uart_process_rx_conn(FAR struct rpmsg_port_uart_s *rpuart,
                                 uint8_t ch)
 {
+  nxmutex_lock(&rpuart->conn_lock);

Review Comment:
   Fixed: the lock now covers only the EVT_CONNED update in 
rpmsg_port_uart_process_rx_conn(), and register/unregister run without it, so a 
re-entry from queue_noavail on the rx thread does not take it again. It stays a 
plain mutex. The baseline and the widened-race test (each side registers once) 
still pass.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to