diff --git a/src/context/mod.rs b/src/context/mod.rs index 37c73f5a37..ab45a3a571 100644 --- a/src/context/mod.rs +++ b/src/context/mod.rs @@ -29,6 +29,14 @@ pub use self::{ pub type ContextLock = RwLock; pub type ArcContextLockWriteGuard = ArcRwLockWriteGuard; +/// Number of priority queues in the per-CPU run queue (DWRR priority +/// count). Kept at 40 to match the historical global `RunContextData.set` +/// length and the existing `SCHED_PRIO_TO_WEIGHT` table in +/// `context/switch.rs`. Each `PerCpuSched.run_queues` entry is one +/// DWRR priority level. Consumers: `crate::percpu::PerCpuSched`, +/// `crate::context::switch`. +pub const RUN_QUEUE_COUNT: usize = 40; + #[cfg(target_arch = "aarch64")] #[path = "arch/aarch64.rs"] mod arch;