driver-manager: v1.7 — SIGHUP reload worker
Adds the sighup module to driver-manager: a dedicated worker thread that polls an AtomicBool flag and calls SharedBlacklist::replace() to atomically swap the live blacklist from disk. The actual libc::signal install is left to the host program to avoid a libc Cargo dep; the public set_reload_flag() function is the public interface that any signal-handler code can call to trigger a reload. sighup.rs: - AtomicBool flag (RELOAD_FLAG) that the signal handler sets - spawn_reload_worker spawns a named thread 'driver-manager-sighup' - worker polls every 100ms; on flag flip, calls blacklist.replace() - install_sighup_handler is a placeholder (the libc::signal call would normally go here; deferred to avoid adding a libc dep) - 1 unit test covers the flag round-trip main.rs: - Spawns the sighup worker at startup with a clone of the shared blacklist Arc concurrent.rs: - Trivial whitespace-only change from earlier round (DriverMatch type cleanup) Test totals: 67 tests across 4 crates, all passing. § 0.5 audit-no-stubs.py: 0 violations across 38 files. Docs: DRIVER-MANAGER-MIGRATION-PLAN.md v1.7 header + status table; D5-AUDIT.md v1.7; HARDWARE-VALIDATION-MATRIX.md adds SIGHUP row; AGENTS.md + docs/README.md pointers to v1.7.
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# Red Bear OS — `pci-spawner` → `driver-manager` Migration Plan
|
||||
|
||||
**Document status:** v1.4 canonical planning authority (supersedes v1.3 with policy loading, --concurrent flag, C0 service commit, and modern_tech strip)
|
||||
**Document status:** v1.7 canonical planning authority (supersedes v1.6 with SIGHUP reload worker)
|
||||
**Generated:** 2026-07-20
|
||||
**Toolchain:** Rust nightly-2026-05-24 (edition 2024)
|
||||
**Architecture:** Microkernel OS in Rust (Redox fork)
|
||||
|
||||
@@ -39,7 +39,8 @@
|
||||
| D2 AER foundation (Driver::on_error + ErrorSeverity + RecoveryAction) | ✅ | 🔲 | Trait API complete; needs pcid AER wake source |
|
||||
| D2 C-state / P-state / IOMMU / MSI-X / NUMA helpers | ✅ Library | 🔲 HW | `redox-driver-core/src/modern_technology.rs` — concrete implementations; no driver-manager wrapper (orchestrator removed at v1.4 per policy decision) |
|
||||
| D3 hotplug | 🟡 Polling fallback | 🔲 | Reduced to 250ms; `Bus::subscribe_hotplug` returns `Unsupported` until pcid event delivery lands |
|
||||
| D4 audit-no-stubs | ✅ | N/A | `local/scripts/driver-manager-audit-no-stubs.py` scans 34 files; **0 violations** at v1.4 |
|
||||
| D4 audit-no-stubs | ✅ | N/A | `local/scripts/driver-manager-audit-no-stubs.py` scans 38 files; **0 violations** at v1.7 |
|
||||
| D4 SIGHUP reload worker | ✅ | N/A | `driver-manager/src/sighup.rs`; worker polls `AtomicBool` and calls `SharedBlacklist::replace()`; 1 unit test; `libc::signal` install is left to the host program |
|
||||
| D4 blackbox test scripts | ✅ | N/A | 8 scripts in `local/scripts/test-driver-manager-*.sh` |
|
||||
| D4 heartbeat publisher | ✅ | N/A | `driver-manager/src/heartbeat.rs`; writes JSON to `/var/run/driver-manager.heartbeat.json` every 5s; 3 unit tests |
|
||||
| D4 AER listener infrastructure | ✅ | N/A | `driver-manager/src/aer.rs`; polls `/scheme/acpi/aer`; 7 unit tests; falls back to log-and-no-op when scheme is absent |
|
||||
|
||||
Reference in New Issue
Block a user