* @brief Preprocess pending signals for a suspended thread * * @param current_thread The thread to check for pending signals * * @details This function checks if the specified thread is suspended and has pending signals. * If both conditions are met, it will wake up/resume the thread to process the signals. */
| 722 | * If both conditions are met, it will wake up/resume the thread to process the signals. |
| 723 | */ |
| 724 | static void _sched_thread_preprocess_signal(struct rt_thread *current_thread) |
| 725 | { |
| 726 | /* should process signal? */ |
| 727 | if (rt_sched_thread_is_suspended(current_thread)) |
| 728 | { |
| 729 | /* if current_thread signal is in pending */ |
| 730 | if ((RT_SCHED_CTX(current_thread).stat & RT_THREAD_STAT_SIGNAL_MASK) & RT_THREAD_STAT_SIGNAL_PENDING) |
| 731 | { |
| 732 | #ifdef RT_USING_SMART |
| 733 | rt_thread_wakeup(current_thread); |
| 734 | #else |
| 735 | rt_thread_resume(current_thread); |
| 736 | #endif |
| 737 | } |
| 738 | } |
| 739 | } |
| 740 | |
| 741 | /** |
| 742 | * @brief Process pending signals for the current thread |
nothing calls this directly
no test coverage detected