다음을 통해 공유


Ready-Event Process (Windows Embedded CE 6.0)

1/6/2010

The ready-event process consists of modules that expose a ready event and threads that wait for a ready event.

Modules that expose a ready-event

When Filesys.exe starts, events are created as soon as the registry is initialized. If the RAM-based registry is in use, the events are created before any applications or drivers are started. If the hive-based registry is in use, the events from the boot hive are created before any applications or drivers are started. Then, when the system hive is loaded, the events from the system hive are created. When the module that added the event data is run, it calls the OpenEvent function to open the event. Any waiting thread is released. The event remains active for the life of the OS.

Call the SetEvent function to set the event.

The module can then use the CloseHandle function to close the event. Because Filesys.exe holds the event open for the life of the OS, the event remains active.

For more information, see OAL Initialization of RAM-based Registry.

Threads that wait for a ready-event

When modules start, they first attempt to call OpenEvent for the API sets to which they are related. If OpenEvent fails, the API set was never, and will never be, registered. If OpenEvent succeeds, the module can call the WaitForSingleObject function to wait for the API set to be registered. This eliminates polling and lets a module know whether an API set will be registered.

To block, use OpenEvent with WaitForSingleObject.

See Also

Concepts

Determining if an API is Ready
Ready-Event Registration