Skip to main content

validate_owner_cpu_context

Function validate_owner_cpu_context 

Source
pub fn validate_owner_cpu_context() -> RuntimeStatus
Expand description

Validates one owner-CPU scheduler-state access.

This is the runtime equivalent of Linux’s lockdep_assert_rq_held(). It must return RuntimeStatus::Success only while the current CPU is pinned by an ordinary IRQ guard or owns an active scheduler baton. Unlike [Self::validate_schedule_context], a completely unguarded task context is invalid here: an interrupt-return scheduler entry could otherwise re-enter over a live mutable crate::runtime::cpu::CpuLocal borrow.