#[non_exhaustive]pub struct Psi {
pub cpu: PsiResource,
pub memory: PsiResource,
pub io: PsiResource,
pub irq: PsiResource,
}Expand description
Bundle of PsiResource for the four kernel-exposed
resources. Same shape used at both system level
(CtprofSnapshot::psi) and per-cgroup
(CgroupStats::psi) — the data source differs but the
kernel emits the same format and field set in both places.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.cpu: PsiResource§memory: PsiResource§io: PsiResource§irq: PsiResourceIRQ pressure. Only the full half is populated by the
kernel (psi_show() sets only_full = res == PSI_IRQ);
irq.some is structurally present but always zero.
Requires both CONFIG_IRQ_TIME_ACCOUNTING at build AND
irqtime_enabled() at runtime (/proc/pressure/irq returns
-EOPNOTSUPP per psi_show() (kernel/sched/psi.c) otherwise);
runtime irqtime is gated by the tsc=... boot param /
irqtime_enabled static branch — when off, the file open
fails and the parser leaves this resource at the default
all-zero value.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Psi
impl<'de> Deserialize<'de> for Psi
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
impl Copy for Psi
Auto Trait Implementations§
impl Freeze for Psi
impl RefUnwindSafe for Psi
impl Send for Psi
impl Sync for Psi
impl Unpin for Psi
impl UnwindSafe for Psi
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more