feat: add kernel ACPI support for querying battery percentage, add battery indicator to desktop, move log state to 0:/state directory

This commit is contained in:
daniel committed 2026-09-11 07:11:48 +02:00
1 parent 0a18b2cf2d
commit e641500b40
34 files changed
+2461 -100

No files matched your search

+6
View File
@@ -504,6 +504,12 @@ namespace montauk::abi {
case SYS_POWERINFO:
if (!UserMemory::Writable<PowerInfo>(frame->arg1)) return -1;
return Sys_PowerInfo((PowerInfo*)frame->arg1);
case SYS_BATTERYINFO:
// Read-only power telemetry, ungated like SYS_POWERINFO: the
// panel indicator has to work in an unprivileged session, which
// holds no device capability to spend on it.
if (!UserMemory::Writable<BatteryInfo>(frame->arg1)) return -1;
return Sys_BatteryInfo((BatteryInfo*)frame->arg1);
case SYS_THREAD_SPAWN:
return Sys_ThreadSpawn(frame->arg1, frame->arg2, frame->arg3);
case SYS_THREAD_EXIT: