File tree Expand file tree Collapse file tree 3 files changed +6
-0
lines changed
tests/drivers/uart/uart_basic_api/src Expand file tree Collapse file tree 3 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -110,6 +110,8 @@ static int test_fifo_read(void)
110110
111111 data_received = false;
112112 while (data_received == false) {
113+ /* Allow other thread/workqueue to work. */
114+ k_yield ();
113115 }
114116
115117 /* Verify uart_irq_rx_disable() */
Original file line number Diff line number Diff line change @@ -124,6 +124,8 @@ static int test_pending(void)
124124 TC_PRINT ("Please send characters to serial console\n" );
125125
126126 while (status == WAIT ) {
127+ /* Allow other thread/workqueue to work. */
128+ k_yield ();
127129 /*
128130 * Wait RX handler change 'status' properly:
129131 * it will change to PASSED or FAILED after
Original file line number Diff line number Diff line change @@ -23,6 +23,8 @@ static int test_poll_in(void)
2323 /* Verify uart_poll_in() */
2424 while (1 ) {
2525 while (uart_poll_in (uart_dev , & recv_char ) < 0 ) {
26+ /* Allow other thread/workqueue to work. */
27+ k_yield ();
2628 }
2729
2830 TC_PRINT ("%c" , recv_char );
You can’t perform that action at this time.
0 commit comments