- StartIOKit( PE_state.deviceTreeHead, PE_state.bootArgs, gPEEFIRuntimeServices, NULL);
+ /*
+ * x86 only minimally enforces lockdown in hardware. Additionally, some pre-lockdown functionality
+ * such as commpage initialization requires IOKit enumeration of CPUs, which is heavily entangled
+ * with the ACPI stack. Therefore, we start the IOKit matching process immediately on x86.
+ */
+ InitIOKit(PE_state.deviceTreeHead);
+ StartIOKitMatching();
+}
+
+void
+PE_lockdown_iokit(void)
+{
+ /* Ensure that at least the CPUs have been enumerated before moving forward. */
+ ml_wait_max_cpus();