Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

129 lines
3.9 KiB

  1. /*++
  2. Copyright (c) 1998 Microsoft Corporation
  3. Module Name:
  4. syspower.h
  5. Abstract:
  6. Contains all the code that deals with the system having to determine
  7. System Power State to Device Power State mappings
  8. Author:
  9. Stephane Plante (splante)
  10. Environment:
  11. Kernel mode only.
  12. Revision History:
  13. October 29th, 1998
  14. --*/
  15. #ifndef _SYSPOWER_H_
  16. #define _SYSPOWER_H_
  17. #define IoCopyDeviceCapabilitiesMapping( Source, Dest ) \
  18. RtlCopyMemory( (PUCHAR) Dest, (PUCHAR) Source, \
  19. (PowerSystemShutdown + 1) * sizeof(DEVICE_POWER_STATE) )
  20. NTSTATUS
  21. ACPISystemPowerDetermineSupportedDeviceStates(
  22. IN PDEVICE_EXTENSION DeviceExtension,
  23. IN SYSTEM_POWER_STATE SystemState,
  24. OUT ULONG *SupportedDeviceStates
  25. );
  26. DEVICE_POWER_STATE
  27. ACPISystemPowerDetermineSupportedDeviceWakeState(
  28. IN PDEVICE_EXTENSION DeviceExtension
  29. );
  30. SYSTEM_POWER_STATE
  31. ACPISystemPowerDetermineSupportedSystemState(
  32. IN PDEVICE_EXTENSION DeviceExtension,
  33. IN DEVICE_POWER_STATE DeviceState
  34. );
  35. NTSTATUS
  36. ACPISystemPowerGetSxD(
  37. IN PDEVICE_EXTENSION DeviceExtension,
  38. IN SYSTEM_POWER_STATE SystemState,
  39. OUT DEVICE_POWER_STATE *DeviceState
  40. );
  41. NTSTATUS
  42. ACPISystemPowerInitializeRootMapping(
  43. IN PDEVICE_EXTENSION DeviceExtension,
  44. IN PDEVICE_CAPABILITIES DeviceCapabilities
  45. );
  46. NTSTATUS
  47. ACPISystemPowerProcessRootMapping(
  48. IN PDEVICE_EXTENSION DeviceExtension,
  49. IN DEVICE_POWER_STATE DeviceMapping[PowerSystemMaximum]
  50. );
  51. NTSTATUS
  52. ACPISystemPowerProcessSxD(
  53. IN PDEVICE_EXTENSION DeviceExtension,
  54. IN DEVICE_POWER_STATE CurrentMapping[PowerSystemMaximum],
  55. IN PBOOLEAN MatchFound
  56. );
  57. NTSTATUS
  58. ACPISystemPowerQueryDeviceCapabilities(
  59. IN PDEVICE_EXTENSION DeviceExtension,
  60. IN PDEVICE_CAPABILITIES DeviceCapabilities
  61. );
  62. NTSTATUS
  63. ACPISystemPowerUpdateDeviceCapabilities(
  64. IN PDEVICE_EXTENSION DeviceExtension,
  65. IN PDEVICE_CAPABILITIES BaseCapabilities,
  66. IN PDEVICE_CAPABILITIES DeviceCapabilities
  67. );
  68. NTSTATUS
  69. ACPISystemPowerUpdateWakeCapabilities(
  70. IN PDEVICE_EXTENSION DeviceExtension,
  71. IN PDEVICE_CAPABILITIES BaseCapabilities,
  72. IN PDEVICE_CAPABILITIES DeviceCapabilities,
  73. IN DEVICE_POWER_STATE CurrentMapping[PowerSystemMaximum],
  74. IN ULONG *SupportedWake,
  75. IN SYSTEM_POWER_STATE *SystemWakeLevel,
  76. IN DEVICE_POWER_STATE *DeviceWakeLevel,
  77. IN DEVICE_POWER_STATE *FilterWakeLevel
  78. );
  79. NTSTATUS
  80. ACPISystemPowerUpdateWakeCapabilitiesForFilters(
  81. IN PDEVICE_EXTENSION DeviceExtension,
  82. IN PDEVICE_CAPABILITIES BaseCapabilities,
  83. IN PDEVICE_CAPABILITIES DeviceCapabilities,
  84. IN DEVICE_POWER_STATE CurrentMapping[PowerSystemMaximum],
  85. IN ULONG *SupportedWake,
  86. IN SYSTEM_POWER_STATE *SystemWakeLevel,
  87. IN DEVICE_POWER_STATE *DeviceWakeLevel,
  88. IN DEVICE_POWER_STATE *FilterWakeLevel
  89. );
  90. NTSTATUS
  91. ACPISystemPowerUpdateWakeCapabilitiesForPDOs(
  92. IN PDEVICE_EXTENSION DeviceExtension,
  93. IN PDEVICE_CAPABILITIES BaseCapabilities,
  94. IN PDEVICE_CAPABILITIES DeviceCapabilities,
  95. IN DEVICE_POWER_STATE CurrentMapping[PowerSystemMaximum],
  96. IN ULONG *SupportedWake,
  97. IN SYSTEM_POWER_STATE *SystemWakeLevel,
  98. IN DEVICE_POWER_STATE *DeviceWakeLevel,
  99. IN DEVICE_POWER_STATE *FilterWakeLevel
  100. );
  101. #endif