Function taskctx::set_current_task_ptr
source · pub unsafe fn set_current_task_ptr<T>(ptr: *const T)
Expand description
Sets the pointer to the current task with preemption-safety.
Preemption may be enabled when calling this function. This function will guarantee the correctness even the current task is preempted.
Safety
The given ptr
must be pointed to a valid task structure.