fix(power): Dell charge limit needs Custom type, not Adaptive
All checks were successful
Check / eval (push) Successful in 2m58s
All checks were successful
Check / eval (push) Successful in 2m58s
charge_control_end_threshold was written (80) but charge_types stayed [Adaptive], which ignores the cap while still reporting it — battery kept charging past 80% on Latitude. Oneshot now selects Custom when a limit is set, Adaptive/Standard when off; sets start hysteresis; doctor warns if type ≠ Custom while limited. V0: flake check --no-build green. V3: re-apply limit, confirm charge_types shows [Custom] and status stops Charging above cap.
This commit is contained in:
@@ -103,6 +103,8 @@
|
||||
batteryChargeLimit = lib.mkOption {
|
||||
type = lib.types.nullOr (lib.types.ints.between 50 100);
|
||||
default = config.nomarchy.settings.power.batteryChargeLimit or null;
|
||||
# Dell Adaptive charge mode ignores the end threshold unless we
|
||||
# also select Custom (power.nix oneshot); see Latitude 5310 QA.
|
||||
example = 80;
|
||||
description = ''
|
||||
Stop charging at this percentage to extend battery lifespan,
|
||||
@@ -112,8 +114,10 @@
|
||||
null leaves charging at the firmware default (menu writes 100).
|
||||
Backend-independent: the menu applies live via sysfs (udev
|
||||
GROUP=users on the threshold node) and persists settings in
|
||||
theme-state; a oneshot re-applies on boot and AC replug. Needs
|
||||
nomarchy.system.power.laptop.
|
||||
theme-state; a oneshot re-applies on boot and AC replug. On
|
||||
Dell (and similar) the oneshot also selects charge type Custom
|
||||
— Adaptive ignores the threshold while still reporting it.
|
||||
Needs nomarchy.system.power.laptop.
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user