Lines Matching refs:sched_state
36 if (MP_STATE_VM(sched_state) == MP_SCHED_IDLE) { in MICROPY_WRAP_MP_SCHED_EXCEPTION()
37 MP_STATE_VM(sched_state) = MP_SCHED_PENDING; in MICROPY_WRAP_MP_SCHED_EXCEPTION()
67 if (MP_STATE_VM(sched_state) == MP_SCHED_PENDING) { in mp_handle_pending()
70 if (MP_STATE_VM(sched_state) == MP_SCHED_PENDING) { in mp_handle_pending()
75 MP_STATE_VM(sched_state) = MP_SCHED_IDLE; in mp_handle_pending()
92 MP_STATE_VM(sched_state) = MP_SCHED_LOCKED; in mp_handle_pending_tail()
107 if (MP_STATE_VM(sched_state) < 0) { in mp_sched_lock()
108 --MP_STATE_VM(sched_state); in mp_sched_lock()
110 MP_STATE_VM(sched_state) = MP_SCHED_LOCKED; in mp_sched_lock()
117 assert(MP_STATE_VM(sched_state) < 0); in mp_sched_unlock()
118 if (++MP_STATE_VM(sched_state) == 0) { in mp_sched_unlock()
121 MP_STATE_VM(sched_state) = MP_SCHED_PENDING; in mp_sched_unlock()
123 MP_STATE_VM(sched_state) = MP_SCHED_IDLE; in mp_sched_unlock()
133 if (MP_STATE_VM(sched_state) == MP_SCHED_IDLE) { in MICROPY_WRAP_MP_SCHED_SCHEDULE()
134 MP_STATE_VM(sched_state) = MP_SCHED_PENDING; in MICROPY_WRAP_MP_SCHED_SCHEDULE()