ember: a registered Igneum Power Helper task counts as permission for the tune (an unelevated measurement engine, Power control forced off, still sets NVIDIA limits through the task with no prompt)
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
parent
3b09b4323d
commit
98d6232f94
1 changed files with 5 additions and 2 deletions
|
|
@ -2295,7 +2295,9 @@ impl Engine {
|
|||
};
|
||||
// NVIDIA control: this process is elevated (direct), or Power control is on so the one-prompt helper may run.
|
||||
// The --sweep job alone never counts: it must not raise a prompt on a PC with nobody there (5 October 2026).
|
||||
let power_control = probe.direct || self.shared.settings.lock().unwrap().power_control;
|
||||
// a registered Igneum Power Helper task (src/powertask.rs) is permission too: it sets limits with no prompt,
|
||||
// so an unelevated measurement engine (Power control forced off) still controls NVIDIA through it
|
||||
let power_control = probe.direct || self.shared.settings.lock().unwrap().power_control || (cfg!(windows) && self.power_task_registered());
|
||||
// AMD's power limit is a percent offset from the default (ADLX): the plan's watts scale becomes a percent
|
||||
// scale (default 100, floor 100 + plimit_min, ceiling 100 + plimit_max), tune_apply sends pct - 100
|
||||
let limits = if c.vendor == "amd" && probe.direct && probe.plimit_max >= probe.plimit_min && probe.plimit_min > -100.0 {
|
||||
|
|
@ -2388,7 +2390,8 @@ impl Engine {
|
|||
|
||||
/// The elevated helper (src/sweep.rs helper_script_*): one administrator prompt; it polls <app>/sweep/cmd.txt.
|
||||
fn sweep_helper_start(&mut self, c: &CardState) -> Result<(), String> {
|
||||
if !self.shared.settings.lock().unwrap().power_control {
|
||||
let task = cfg!(windows) && self.power_task_registered();
|
||||
if !task && !self.shared.settings.lock().unwrap().power_control {
|
||||
return Err("Power control is off in Settings".into());
|
||||
}
|
||||
let dir = self.sweep_dir();
|
||||
|
|
|
|||
Loading…
Reference in a new issue