reorg: move power-protocol to library/protocol; finish the protocol tree

power-protocol -> library/protocol/power/power-protocol.zig. Its two consumers
(init and the acpi discovery service) import it directly; the
runtime.power_protocol re-export and the runtime module import are dropped (no
runtime client speaks it). The now-empty system/services/power/ is removed.

This completes library/protocol/: every driver<->service wire contract lives
there and is imported by module name, no protocol is re-exported through
runtime, and the alias chaos (dp/sp, mixed protocol/<x>_protocol) is resolved.
virtio-gpu-protocol stays a driver-private relative import (a hardware command
set, not a driver<->service seam — like virtio-pci.zig beside it).

zig build + test green; power-button, orderly-shutdown pass.
This commit is contained in:
Daniel Samson
2026-07-22 21:04:37 +01:00
parent 44122bd44d
commit 3c9475e33a
5 changed files with 7 additions and 8 deletions
-3
View File
@@ -24,9 +24,6 @@ pub const start = @import("start.zig");
/// protocol itself is the library/protocol/device-manager module, imported
/// directly by drivers and services that speak it.
pub const device_manager = @import("device-manager.zig");
/// The power protocol: events (button, lid, battery) + shutdown (docs/power.md).
pub const power_protocol = @import("power-protocol");
/// Keyboard-event listening (subscribe/next) and broadcasting (publish), over the input
/// service. See library/runtime/input.zig and system/services/input/.
pub const input = @import("input.zig");