include vmm.inc VMMCall VMM_GetSystemInitState mov [InitState], eax
Retrieves the current system initialization state. Uses EAX, ECX, Flags.
The following table identifies initialization milestones and return values for VMM_GetSystemInitState. Milestones are listed in the table in chronological order. When a milestone completes, this service returns the value (one of the values) listed to the right of the milestone. The first value is returned if the first milestone has not been completed.
Milestone | VMM_GetSystemInitState return value |
SYSSTATE_PRESYSCRITINIT (00000000h) | SYS_CRITICAL_Init is broadcast |
SYSSTATE_PREDEVICEINIT (10000000h) | DEVICE_INIT is broadcast |
SYSSTATE_PREINITCOMPLETE (20000000h) | INIT_COMPLETE is broadcast |
SYSSTATE_VXDINITCOMPLETED (40000000h) | KERNEL32_INITIALIZED is broadcast |
SYSSTATE_KERNEL32INITED (50000000h) | KERNEL32_SHUTDOWN is broadcast |
SYSSTATE_KERNEL32TERMINATED (A0000000h) STATE_PRESYSVMTERMINATE (B0000000h) | SYS_VM_TERMINATE is broadcast |
SYSSTATE_PRESYSTEMEXIT (E0000000h) | SYSTEM_EXIT is broadcast |
SYSSTATE_PRESYSTEMEXIT2 (E4000000h) | SYSTEM_EXIT2 is broadcast |
SYSSTATE_PRESYSCRITEXIT (F0000000h) | SYS_CRITICAL_EXIT is broadcast |
SYSSTATE_PRESYSCRITEXIT2 (F4000000h) | SYS_CRITICAL_EXIT2 is broadcast. |
SYSSTATE_POSTSYSCRITEXIT2 (FFF00000h) | Return to real mode |
Future versions of Windows may have additional initialization states with values between the ones defined here, which implies that you should use a relational comparison to test the initialized state. Currently, this service returns zero in ECX, but additional information may be returned in this register in the future.