#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum SchedulerMode {
Reflex,
Flow,
Recovery,
}
#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)]
#[repr(transparent)]
pub struct Priority(u8);
impl Priority {
pub const MAX: Self = Self(255);
pub const MIN: Self = Self(0);
pub const DEFAULT: Self = Self(128);
#[must_use]
pub const fn new(val: u8) -> Self {
Self(val)
}
#[must_use]
pub const fn as_u8(self) -> u8 {
self.0
}
}
#[derive(Debug, Clone, Copy)]
pub struct EpochConfig {
pub interval_ns: u64,
pub max_switches: u16,
}
impl Default for EpochConfig {
fn default() -> Self {
Self {
interval_ns: 10_000_000, max_switches: 64,
}
}
}
#[derive(Debug, Clone, Copy)]
pub struct EpochSummary {
pub epoch: u32,
pub switch_count: u16,
pub runnable_count: u16,
}