* switch thread in interrupt * * @author LXZ (2014/11/8) * * @param rt_uint32_t from * @param rt_uint32_t to */
| 144 | * @param rt_uint32_t to |
| 145 | */ |
| 146 | void rt_hw_context_switch(rt_uint32_t from, rt_uint32_t to) |
| 147 | { |
| 148 | if (rt_thread_switch_interrupt_flag == 0) |
| 149 | { |
| 150 | rt_thread_switch_interrupt_flag = 1; |
| 151 | rt_interrupt_from_thread = from; |
| 152 | } |
| 153 | |
| 154 | rt_interrupt_to_thread = to; |
| 155 | ENTER_INTERRUPT(); |
| 156 | } |
| 157 | /** |
| 158 | * switch thread out the interrupt |
| 159 | * |
no outgoing calls
no test coverage detected