Книга: Microsoft Windows Embedded CE 6.0 Exam Preparation Kit

IOControl

IOControl

The best way to implement power manager in a stream driver is to add support for power management I/O control codes to the driver's IOControl function. When you notify Power Manager about your driver's power management capabilities through an IClass registry entry or the AdvertiseInterface function, your driver receives corresponding notification messages.

Table 6-8 lists the IOCTLs that Power Manager can send to a device driver to perform power management-related tasks.

Table 6-8 Power management IOCTLs

Function Description
IOCTL_POWER_CAPABILITIES Requests information on what power states the driver supports. Note that the driver can still be set to other power states (D0 through D4).
IOCTL_POWER_GET Requests the current power state of the driver.
IOCTL_POWER_SET Sets the power state of the driver. The driver maps the received power state number to actual settings and changes the device state. The new device driver power state should be returned to Power Manager in the output buffer.
IOCTL_POWER_QUERY Power Manger checks to see if the driver is able to change the state of the device. This function is deprecated.
IOCTL_REGISTER_POWER_RELATIONSHIP Enables a device driver to register as the proxy for another device driver, so that Power Manager passes all power requests to this device driver.

Оглавление книги

Оглавление статьи/книги

Генерация: 1.122. Запросов К БД/Cache: 3 / 1
поделиться
Вверх Вниз