update docs + agents

This commit is contained in:
2026-02-27 17:04:47 +01:00
parent fe1f58b5ce
commit 4f54fd81ce
15 changed files with 508 additions and 99 deletions

View File

@@ -133,6 +133,23 @@ impl SensorBus for GenericLinuxSal {
Err(anyhow!("Could not determine CPU frequency"))
}
}
fn get_throttling_status(&self) -> Result<bool> {
// Fallback: check if any cooling device is active (cur_state > 0)
let cooling_base = self.ctx.sysfs_base.join("sys/class/thermal");
if let Ok(entries) = fs::read_dir(cooling_base) {
for entry in entries.flatten() {
if entry.file_name().to_string_lossy().starts_with("cooling_device") {
if let Ok(state) = fs::read_to_string(entry.path().join("cur_state")) {
if state.trim().parse::<u32>().unwrap_or(0) > 0 {
return Ok(true);
}
}
}
}
}
Ok(false)
}
}
impl ActuatorBus for GenericLinuxSal {