anchao commented on code in PR #17499:
URL: https://github.com/apache/nuttx/pull/17499#discussion_r2619915012


##########
drivers/serial/uart_rpmsg.c:
##########
@@ -387,13 +388,15 @@ static int uart_rpmsg_ept_cb(FAR struct rpmsg_endpoint 
*ept, FAR void *data,
     }
   else if (header->command == UART_RPMSG_TTY_WRITE)
     {
+      irqstate_t flags;
+
       /* Get write-cmd, there are some data, we need receive them */
 
-      nxmutex_lock(&dev->recv.lock);
+      flags = uart_spinlock(dev, true);

Review Comment:
   could we keep the mutex_lock? critical_section + sched_lock not equal to 
mutex_lock



-- 
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