diff --git a/hwd/src/main.rs b/hwd/src/main.rs index ed62b87e4d..afe85a1f45 100644 --- a/hwd/src/main.rs +++ b/hwd/src/main.rs @@ -1,3 +1,5 @@ +use std::process::Command; + mod backend; use self::backend::{AcpiBackend, Backend, DeviceTreeBackend, LegacyBackend}; @@ -33,6 +35,22 @@ fn main() { } }; + //TODO: launch pcid based on backend information? + // Must launch after acpid but before probe calls /scheme/acpi/symbols + match Command::new("pcid").spawn() { + Ok(mut child) => match child.wait() { + Ok(status) => if !status.success() { + log::error!("pcid exited with status {}", status); + }, + Err(err) => { + log::error!("failed to wait for pcid: {}", err); + } + }, + Err(err) => { + log::error!("failed to spawn pcid: {}", err); + } + } + //TODO: HWD is meant to locate PCI/XHCI/etc devices in ACPI and DeviceTree definitions and start their drivers match backend.probe() { Ok(()) => {}