Move some ddk defines to winnt.h as per MSDN documentation
* include/ddk/batclass.h (BATTERY_REPORTING_SCALE) Move structure from here... * include/winnt.h (BATTERY_REPORTING_SCALE): To here. * include/ddk/ntapi.h (JOBOBJECT_*): Remove structures and enums definitions. (JOB_OBJECT*): Move defines from here... * include/winnt.h (JOB_OBJECT* ): To here. * include/ddk/ntpoapi.h (LATENCY_TIME, POWER_ACTION_POLICY, SYSTEM_POWER_LEVEL, SYSTEM_POWER_POLICY, PROCESSOR_POWER_POLICY_INFO, PROCESSOR_POWER_POLICY, ADMINISTRATOR_POWER_POLICY, SYSTEM_POWER_INFORMATION, PROCESSOR_POWER_INFORMATION, SYSTEM_BATTERY_STATE, SYSTEM_POWER_CAPABILITIES): Move enums, structures and associated defines from here ... * include/winnt.h: (LATENCY_TIME, POWER_ACTION_POLICY, SYSTEM_POWER_LEVEL, SYSTEM_POWER_POLICY, PROCESSOR_POWER_POLICY_INFO, PROCESSOR_POWER_POLICY, ADMINISTRATOR_POWER_POLICY, SYSTEM_POWER_INFORMATION, PROCESSOR_POWER_INFORMATION, SYSTEM_BATTERY_STATE, SYSTEM_POWER_CAPABILITIES):To here. * include/ddk/winddk.h (DEVICE_POWER_STATE, SYSTEM_POWER_STATE, POWER_ACTION): Move enums from here... * include/winnt.h (DEVICE_POWER_STATE, SYSTEM_POWER_STATE, POWER_ACTION): To here.
This commit is contained in:
parent
85738bf7e3
commit
200738932f
|
@ -1,3 +1,34 @@
|
||||||
|
2003-03-26 Danny Smith <dannysmith@users.sourceforge.net>
|
||||||
|
|
||||||
|
* include/ddk/batclass.h (BATTERY_REPORTING_SCALE)
|
||||||
|
Move structure from here...
|
||||||
|
* include/winnt.h (BATTERY_REPORTING_SCALE): To here.
|
||||||
|
|
||||||
|
* include/ddk/ntapi.h (JOBOBJECT_*):
|
||||||
|
Remove structures and enums definitions.
|
||||||
|
(JOB_OBJECT*): Move defines from here...
|
||||||
|
* include/winnt.h (JOB_OBJECT* ): To here.
|
||||||
|
|
||||||
|
* include/ddk/ntpoapi.h (LATENCY_TIME, POWER_ACTION_POLICY,
|
||||||
|
SYSTEM_POWER_LEVEL, SYSTEM_POWER_POLICY,
|
||||||
|
PROCESSOR_POWER_POLICY_INFO, PROCESSOR_POWER_POLICY,
|
||||||
|
ADMINISTRATOR_POWER_POLICY, SYSTEM_POWER_INFORMATION,
|
||||||
|
PROCESSOR_POWER_INFORMATION, SYSTEM_BATTERY_STATE,
|
||||||
|
SYSTEM_POWER_CAPABILITIES): Move enums, structures
|
||||||
|
and associated defines from here ...
|
||||||
|
* include/winnt.h: (LATENCY_TIME, POWER_ACTION_POLICY,
|
||||||
|
SYSTEM_POWER_LEVEL, SYSTEM_POWER_POLICY,
|
||||||
|
PROCESSOR_POWER_POLICY_INFO, PROCESSOR_POWER_POLICY,
|
||||||
|
ADMINISTRATOR_POWER_POLICY, SYSTEM_POWER_INFORMATION,
|
||||||
|
PROCESSOR_POWER_INFORMATION, SYSTEM_BATTERY_STATE,
|
||||||
|
SYSTEM_POWER_CAPABILITIES):To here.
|
||||||
|
|
||||||
|
* include/ddk/winddk.h (DEVICE_POWER_STATE,
|
||||||
|
SYSTEM_POWER_STATE, POWER_ACTION): Move enums
|
||||||
|
from here...
|
||||||
|
* include/winnt.h (DEVICE_POWER_STATE,
|
||||||
|
SYSTEM_POWER_STATE, POWER_ACTION): To here.
|
||||||
|
|
||||||
2003-03-19 Danny Smith <dannysmith@users.sourceforge.net>
|
2003-03-19 Danny Smith <dannysmith@users.sourceforge.net>
|
||||||
|
|
||||||
*lib/ndis.def (NdisAllocateMemory): Correct stdcall suffix.
|
*lib/ndis.def (NdisAllocateMemory): Correct stdcall suffix.
|
||||||
|
|
|
@ -105,11 +105,6 @@ typedef struct _BATTERY_NOTIFY {
|
||||||
ULONG HighCapacity;
|
ULONG HighCapacity;
|
||||||
} BATTERY_NOTIFY, *PBATTERY_NOTIFY;
|
} BATTERY_NOTIFY, *PBATTERY_NOTIFY;
|
||||||
|
|
||||||
typedef struct _BATTERY_REPORTING_SCALE {
|
|
||||||
ULONG Granularity;
|
|
||||||
ULONG Capacity;
|
|
||||||
} BATTERY_REPORTING_SCALE, *PBATTERY_REPORTING_SCALE;
|
|
||||||
|
|
||||||
/* BATTERY_STATUS.PowerState flags */
|
/* BATTERY_STATUS.PowerState flags */
|
||||||
#define BATTERY_POWER_ON_LINE 0x00000001
|
#define BATTERY_POWER_ON_LINE 0x00000001
|
||||||
#define BATTERY_DISCHARGING 0x00000002
|
#define BATTERY_DISCHARGING 0x00000002
|
||||||
|
@ -129,7 +124,6 @@ typedef struct _BATTERY_STATUS {
|
||||||
LONG Rate;
|
LONG Rate;
|
||||||
} BATTERY_STATUS, *PBATTERY_STATUS;
|
} BATTERY_STATUS, *PBATTERY_STATUS;
|
||||||
|
|
||||||
|
|
||||||
/* BATTERY_INFORMATION.Capacity constants */
|
/* BATTERY_INFORMATION.Capacity constants */
|
||||||
#define BATTERY_UNKNOWN_CAPACITY 0xFFFFFFFF
|
#define BATTERY_UNKNOWN_CAPACITY 0xFFFFFFFF
|
||||||
|
|
||||||
|
|
|
@ -1615,7 +1615,6 @@ typedef struct _DEBUG_LOCK_INFORMATION {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Jobs */
|
/* Jobs */
|
||||||
|
|
||||||
NTOSAPI
|
NTOSAPI
|
||||||
|
@ -1648,18 +1647,6 @@ ZwAssignProcessToJobObject(
|
||||||
IN HANDLE JobHandle,
|
IN HANDLE JobHandle,
|
||||||
IN HANDLE ProcessHandle);
|
IN HANDLE ProcessHandle);
|
||||||
|
|
||||||
typedef enum _JOBOBJECTINFOCLASS {
|
|
||||||
JobObjectBasicAccountingInformation = 1,
|
|
||||||
JobObjectBasicLimitInformation,
|
|
||||||
JobObjectBasicProcessIdList,
|
|
||||||
JobObjectBasicUIRestrictions,
|
|
||||||
JobObjectSecurityLimitInformation,
|
|
||||||
JobObjectEndOfJobTimeInformation,
|
|
||||||
JobObjectAssociateCompletionPortInformation,
|
|
||||||
JobObjectBasicAndIoAccountingInformation,
|
|
||||||
JobObjectExtendedLimitInformation
|
|
||||||
} JOBOBJECTINFOCLASS;
|
|
||||||
|
|
||||||
NTOSAPI
|
NTOSAPI
|
||||||
NTSTATUS
|
NTSTATUS
|
||||||
NTAPI
|
NTAPI
|
||||||
|
@ -1679,117 +1666,6 @@ ZwSetInformationJobObject(
|
||||||
IN PVOID JobInformation,
|
IN PVOID JobInformation,
|
||||||
IN ULONG JobInformationLength);
|
IN ULONG JobInformationLength);
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_BASIC_ACCOUNTING_INFORMATION {
|
|
||||||
LARGE_INTEGER TotalUserTime;
|
|
||||||
LARGE_INTEGER TotalKernelTime;
|
|
||||||
LARGE_INTEGER ThisPeriodTotalUserTime;
|
|
||||||
LARGE_INTEGER ThisPeriodTotalKernelTime;
|
|
||||||
ULONG TotalPageFaultCount;
|
|
||||||
ULONG TotalProcesses;
|
|
||||||
ULONG ActiveProcesses;
|
|
||||||
ULONG TotalTerminatedProcesses;
|
|
||||||
} JOBOBJECT_BASIC_ACCOUNTING_INFORMATION, *PJOBOBJECT_BASIC_ACCOUNTING_INFORMATION;
|
|
||||||
|
|
||||||
/* JOBOBJECT_BASIC_LIMIT_INFORMATION.LimitFlags constants */
|
|
||||||
#define JOB_OBJECT_LIMIT_WORKINGSET 0x0001
|
|
||||||
#define JOB_OBJECT_LIMIT_PROCESS_TIME 0x0002
|
|
||||||
#define JOB_OBJECT_LIMIT_JOB_TIME 0x0004
|
|
||||||
#define JOB_OBJECT_LIMIT_ACTIVE_PROCESS 0x0008
|
|
||||||
#define JOB_OBJECT_LIMIT_AFFINITY 0x0010
|
|
||||||
#define JOB_OBJECT_LIMIT_PRIORITY_CLASS 0x0020
|
|
||||||
#define JOB_OBJECT_LIMIT_PRESERVE_JOB_TIME 0x0040
|
|
||||||
#define JOB_OBJECT_LIMIT_SCHEDULING_CLASS 0x0080
|
|
||||||
#define JOB_OBJECT_LIMIT_PROCESS_MEMORY 0x0100
|
|
||||||
#define JOB_OBJECT_LIMIT_JOB_MEMORY 0x0200
|
|
||||||
#define JOB_OBJECT_LIMIT_DIE_ON_UNHANDLED_EXCEPTION 0x0400
|
|
||||||
#define JOB_OBJECT_BREAKAWAY_OK 0x0800
|
|
||||||
#define JOB_OBJECT_SILENT_BREAKAWAY 0x1000
|
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_BASIC_LIMIT_INFORMATION {
|
|
||||||
LARGE_INTEGER PerProcessUserTimeLimit;
|
|
||||||
LARGE_INTEGER PerJobUserTimeLimit;
|
|
||||||
ULONG LimitFlags;
|
|
||||||
ULONG MinimumWorkingSetSize;
|
|
||||||
ULONG MaximumWorkingSetSize;
|
|
||||||
ULONG ActiveProcessLimit;
|
|
||||||
ULONG Affinity;
|
|
||||||
ULONG PriorityClass;
|
|
||||||
ULONG SchedulingClass;
|
|
||||||
} JOBOBJECT_BASIC_LIMIT_INFORMATION, *PJOBOBJECT_BASIC_LIMIT_INFORMATION;
|
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_BASIC_PROCESS_ID_LIST {
|
|
||||||
ULONG NumberOfAssignedProcesses;
|
|
||||||
ULONG NumberOfProcessIdsInList;
|
|
||||||
ULONG_PTR ProcessIdList[1];
|
|
||||||
} JOBOBJECT_BASIC_PROCESS_ID_LIST, *PJOBOBJECT_BASIC_PROCESS_ID_LIST;
|
|
||||||
|
|
||||||
/* JOBOBJECT_BASIC_UI_RESTRICTIONS.UIRestrictionsClass constants */
|
|
||||||
#define JOB_OBJECT_UILIMIT_HANDLES 0x0001
|
|
||||||
#define JOB_OBJECT_UILIMIT_READCLIPBOARD 0x0002
|
|
||||||
#define JOB_OBJECT_UILIMIT_WRITECLIPBOARD 0x0004
|
|
||||||
#define JOB_OBJECT_UILIMIT_SYSTEMPARAMETERS 0x0008
|
|
||||||
#define JOB_OBJECT_UILIMIT_DISPLAYSETTINGS 0x0010
|
|
||||||
#define JOB_OBJECT_UILIMIT_GLOBALATOMS 0x0020
|
|
||||||
#define JOB_OBJECT_UILIMIT_DESKTOP 0x0040
|
|
||||||
#define JOB_OBJECT_UILIMIT_EXITWINDOWS 0x0080
|
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_BASIC_UI_RESTRICTIONS {
|
|
||||||
ULONG UIRestrictionsClass;
|
|
||||||
} JOBOBJECT_BASIC_UI_RESTRICTIONS, *PJOBOBJECT_BASIC_UI_RESTRICTIONS;
|
|
||||||
|
|
||||||
/* JOBOBJECT_SECURITY_LIMIT_INFORMATION.SecurityLimitFlags constants */
|
|
||||||
#define JOB_OBJECT_SECURITY_NO_ADMIN 0x0001
|
|
||||||
#define JOB_OBJECT_SECURITY_RESTRICTED_TOKEN 0x0002
|
|
||||||
#define JOB_OBJECT_SECURITY_ONLY_TOKEN 0x0004
|
|
||||||
#define JOB_OBJECT_SECURITY_FILTER_TOKENS 0x0008
|
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_SECURITY_LIMIT_INFORMATION {
|
|
||||||
ULONG SecurityLimitFlags;
|
|
||||||
HANDLE JobToken;
|
|
||||||
PTOKEN_GROUPS SidsToDisable;
|
|
||||||
PTOKEN_PRIVILEGES PrivilegesToDelete;
|
|
||||||
PTOKEN_GROUPS RestrictedSids;
|
|
||||||
} JOBOBJECT_SECURITY_LIMIT_INFORMATION, *PJOBOBJECT_SECURITY_LIMIT_INFORMATION;
|
|
||||||
|
|
||||||
/* JOBOBJECT_END_OF_JOB_TIME_INFORMATION.EndOfJobTimeAction constants */
|
|
||||||
#define JOB_OBJECT_TERMINATE_AT_END_OF_JOB 0
|
|
||||||
#define JOB_OBJECT_POST_AT_END_OF_JOB 1
|
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_END_OF_JOB_TIME_INFORMATION {
|
|
||||||
ULONG EndOfJobTimeAction;
|
|
||||||
} JOBOBJECT_END_OF_JOB_TIME_INFORMATION, *PJOBOBJECT_END_OF_JOB_TIME_INFORMATION;
|
|
||||||
|
|
||||||
#define JOB_OBJECT_MSG_END_OF_JOB_TIME 1
|
|
||||||
#define JOB_OBJECT_MSG_END_OF_PROCESS_TIME 2
|
|
||||||
#define JOB_OBJECT_MSG_ACTIVE_PROCESS_LIMIT 3
|
|
||||||
#define JOB_OBJECT_MSG_ACTIVE_PROCESS_ZERO 4
|
|
||||||
#define JOB_OBJECT_MSG_NEW_PROCESS 6
|
|
||||||
#define JOB_OBJECT_MSG_EXIT_PROCESS 7
|
|
||||||
#define JOB_OBJECT_MSG_ABNORMAL_EXIT_PROCESS 8
|
|
||||||
#define JOB_OBJECT_MSG_PROCESS_MEMORY_LIMIT 9
|
|
||||||
#define JOB_OBJECT_MSG_JOB_MEMORY_LIMIT 10
|
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_ASSOCIATE_COMPLETION_PORT {
|
|
||||||
PVOID CompletionKey;
|
|
||||||
HANDLE CompletionPort;
|
|
||||||
} JOBOBJECT_ASSOCIATE_COMPLETION_PORT, *PJOBOBJECT_ASSOCIATE_COMPLETION_PORT;
|
|
||||||
|
|
||||||
typedef struct JOBOBJECT_BASIC_AND_IO_ACCOUNTING_INFORMATION {
|
|
||||||
JOBOBJECT_BASIC_ACCOUNTING_INFORMATION BasicInfo;
|
|
||||||
IO_COUNTERS IoInfo;
|
|
||||||
} JOBOBJECT_BASIC_AND_IO_ACCOUNTING_INFORMATION, *PJOBOBJECT_BASIC_AND_IO_ACCOUNTING_INFORMATION;
|
|
||||||
|
|
||||||
typedef struct _JOBOBJECT_EXTENDED_LIMIT_INFORMATION {
|
|
||||||
JOBOBJECT_BASIC_LIMIT_INFORMATION BasicLimitInformation;
|
|
||||||
IO_COUNTERS IoInfo;
|
|
||||||
ULONG ProcessMemoryLimit;
|
|
||||||
ULONG JobMemoryLimit;
|
|
||||||
ULONG PeakProcessMemoryUsed;
|
|
||||||
ULONG PeakJobMemoryUsed;
|
|
||||||
} JOBOBJECT_EXTENDED_LIMIT_INFORMATION, *PJOBOBJECT_EXTENDED_LIMIT_INFORMATION;
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* Tokens */
|
/* Tokens */
|
||||||
|
|
||||||
|
|
|
@ -36,19 +36,6 @@ extern "C" {
|
||||||
#include "ntddk.h"
|
#include "ntddk.h"
|
||||||
#include "batclass.h"
|
#include "batclass.h"
|
||||||
|
|
||||||
|
|
||||||
#define ES_SYSTEM_REQUIRED 0x00000001
|
|
||||||
#define ES_DISPLAY_REQUIRED 0x00000002
|
|
||||||
#define ES_USER_PRESENT 0x00000004
|
|
||||||
#define ES_CONTINUOUS 0x80000000
|
|
||||||
|
|
||||||
typedef enum _LATENCY_TIME {
|
|
||||||
LT_DONT_CARE,
|
|
||||||
LT_LOWEST_LATENCY
|
|
||||||
} LATENCY_TIME, *PLATENCY_TIME;
|
|
||||||
|
|
||||||
#define POWER_SYSTEM_MAXIMUM PowerSystemMaximum
|
|
||||||
|
|
||||||
typedef enum _POWER_INFORMATION_LEVEL {
|
typedef enum _POWER_INFORMATION_LEVEL {
|
||||||
SystemPowerPolicyAc,
|
SystemPowerPolicyAc,
|
||||||
SystemPowerPolicyDc,
|
SystemPowerPolicyDc,
|
||||||
|
@ -196,107 +183,6 @@ typedef struct _PROCESSOR_STATE_HANDLER2 {
|
||||||
PROCESSOR_PERF_LEVEL PerfLevel[1];
|
PROCESSOR_PERF_LEVEL PerfLevel[1];
|
||||||
} PROCESSOR_STATE_HANDLER2, *PPROCESSOR_STATE_HANDLER2;
|
} PROCESSOR_STATE_HANDLER2, *PPROCESSOR_STATE_HANDLER2;
|
||||||
|
|
||||||
/* POWER_ACTION_POLICY.Flags constants */
|
|
||||||
#define POWER_ACTION_QUERY_ALLOWED 0x00000001
|
|
||||||
#define POWER_ACTION_UI_ALLOWED 0x00000002
|
|
||||||
#define POWER_ACTION_OVERRIDE_APPS 0x00000004
|
|
||||||
#define POWER_ACTION_LIGHTEST_FIRST 0x10000000
|
|
||||||
#define POWER_ACTION_LOCK_CONSOLE 0x20000000
|
|
||||||
#define POWER_ACTION_DISABLE_WAKES 0x40000000
|
|
||||||
#define POWER_ACTION_CRITICAL 0x80000000
|
|
||||||
|
|
||||||
/* POWER_ACTION_POLICY.EventCode constants */
|
|
||||||
#define POWER_LEVEL_USER_NOTIFY_TEXT 0x00000001
|
|
||||||
#define POWER_LEVEL_USER_NOTIFY_SOUND 0x00000002
|
|
||||||
#define POWER_LEVEL_USER_NOTIFY_EXEC 0x00000004
|
|
||||||
#define POWER_USER_NOTIFY_BUTTON 0x00000008
|
|
||||||
#define POWER_USER_NOTIFY_SHUTDOWN 0x00000010
|
|
||||||
#define POWER_FORCE_TRIGGER_RESET 0x80000000
|
|
||||||
|
|
||||||
typedef struct _POWER_ACTION_POLICY {
|
|
||||||
POWER_ACTION Action;
|
|
||||||
ULONG Flags;
|
|
||||||
ULONG EventCode;
|
|
||||||
} POWER_ACTION_POLICY, *PPOWER_ACTION_POLICY;
|
|
||||||
|
|
||||||
typedef struct _SYSTEM_POWER_LEVEL {
|
|
||||||
BOOLEAN Enable;
|
|
||||||
UCHAR Spare[3];
|
|
||||||
ULONG BatteryLevel;
|
|
||||||
POWER_ACTION_POLICY PowerPolicy;
|
|
||||||
SYSTEM_POWER_STATE MinSystemState;
|
|
||||||
} SYSTEM_POWER_LEVEL, *PSYSTEM_POWER_LEVEL;
|
|
||||||
|
|
||||||
#define DISCHARGE_POLICY_CRITICAL 0
|
|
||||||
#define DISCHARGE_POLICY_LOW 1
|
|
||||||
#define NUM_DISCHARGE_POLICIES 4
|
|
||||||
|
|
||||||
#define PO_THROTTLE_NONE 0
|
|
||||||
#define PO_THROTTLE_CONSTANT 1
|
|
||||||
#define PO_THROTTLE_DEGRADE 2
|
|
||||||
#define PO_THROTTLE_ADAPTIVE 3
|
|
||||||
#define PO_THROTTLE_MAXIMUM 4
|
|
||||||
|
|
||||||
typedef struct _SYSTEM_POWER_POLICY {
|
|
||||||
ULONG Revision;
|
|
||||||
POWER_ACTION_POLICY PowerButton;
|
|
||||||
POWER_ACTION_POLICY SleepButton;
|
|
||||||
POWER_ACTION_POLICY LidClose;
|
|
||||||
SYSTEM_POWER_STATE LidOpenWake;
|
|
||||||
ULONG Reserved;
|
|
||||||
POWER_ACTION_POLICY Idle;
|
|
||||||
ULONG IdleTimeout;
|
|
||||||
UCHAR IdleSensitivity;
|
|
||||||
UCHAR DynamicThrottle;
|
|
||||||
UCHAR Spare2[2];
|
|
||||||
SYSTEM_POWER_STATE MinSleep;
|
|
||||||
SYSTEM_POWER_STATE MaxSleep;
|
|
||||||
SYSTEM_POWER_STATE ReducedLatencySleep;
|
|
||||||
ULONG WinLogonFlags;
|
|
||||||
ULONG Spare3;
|
|
||||||
ULONG DozeS4Timeout;
|
|
||||||
ULONG BroadcastCapacityResolution;
|
|
||||||
SYSTEM_POWER_LEVEL DischargePolicy[NUM_DISCHARGE_POLICIES];
|
|
||||||
ULONG VideoTimeout;
|
|
||||||
BOOLEAN VideoDimDisplay;
|
|
||||||
ULONG VideoReserved[3];
|
|
||||||
ULONG SpindownTimeout;
|
|
||||||
BOOLEAN OptimizeForPower;
|
|
||||||
UCHAR FanThrottleTolerance;
|
|
||||||
UCHAR ForcedThrottle;
|
|
||||||
UCHAR MinThrottle;
|
|
||||||
POWER_ACTION_POLICY OverThrottled;
|
|
||||||
} SYSTEM_POWER_POLICY, *PSYSTEM_POWER_POLICY;
|
|
||||||
|
|
||||||
typedef struct _PROCESSOR_POWER_POLICY_INFO {
|
|
||||||
ULONG TimeCheck;
|
|
||||||
ULONG DemoteLimit;
|
|
||||||
ULONG PromoteLimit;
|
|
||||||
UCHAR DemotePercent;
|
|
||||||
UCHAR PromotePercent;
|
|
||||||
UCHAR Spare[2];
|
|
||||||
ULONG AllowDemotion : 1;
|
|
||||||
ULONG AllowPromotion : 1;
|
|
||||||
ULONG Reserved : 30;
|
|
||||||
} PROCESSOR_POWER_POLICY_INFO, *PPROCESSOR_POWER_POLICY_INFO;
|
|
||||||
|
|
||||||
typedef struct _PROCESSOR_POWER_POLICY {
|
|
||||||
ULONG Revision;
|
|
||||||
UCHAR DynamicThrottle;
|
|
||||||
UCHAR Spare[3];
|
|
||||||
ULONG Reserved;
|
|
||||||
ULONG PolicyCount;
|
|
||||||
PROCESSOR_POWER_POLICY_INFO Policy[3];
|
|
||||||
} PROCESSOR_POWER_POLICY, *PPROCESSOR_POWER_POLICY;
|
|
||||||
|
|
||||||
typedef struct _ADMINISTRATOR_POWER_POLICY {
|
|
||||||
SYSTEM_POWER_STATE MinSleep;
|
|
||||||
SYSTEM_POWER_STATE MaxSleep;
|
|
||||||
ULONG MinVideoTimeout;
|
|
||||||
ULONG MaxVideoTimeout;
|
|
||||||
ULONG MinSpindownTimeout;
|
|
||||||
ULONG MaxSpindownTimeout;
|
|
||||||
} ADMINISTRATOR_POWER_POLICY, *PADMINISTRATOR_POWER_POLICY;
|
|
||||||
|
|
||||||
NTOSAPI
|
NTOSAPI
|
||||||
NTSTATUS
|
NTSTATUS
|
||||||
|
@ -355,13 +241,6 @@ NtRequestDeviceWakeup(
|
||||||
|
|
||||||
#define WINLOGON_LOCK_ON_SLEEP 0x00000001
|
#define WINLOGON_LOCK_ON_SLEEP 0x00000001
|
||||||
|
|
||||||
typedef struct _SYSTEM_POWER_INFORMATION {
|
|
||||||
ULONG MaxIdlenessAllowed;
|
|
||||||
ULONG Idleness;
|
|
||||||
ULONG TimeRemaining;
|
|
||||||
UCHAR CoolingMode;
|
|
||||||
} SYSTEM_POWER_INFORMATION, *PSYSTEM_POWER_INFORMATION;
|
|
||||||
|
|
||||||
typedef struct _PROCESSOR_POWER_INFORMATION {
|
typedef struct _PROCESSOR_POWER_INFORMATION {
|
||||||
ULONG Number;
|
ULONG Number;
|
||||||
ULONG MaxMhz;
|
ULONG MaxMhz;
|
||||||
|
@ -371,50 +250,6 @@ typedef struct _PROCESSOR_POWER_INFORMATION {
|
||||||
ULONG CurrentIdleState;
|
ULONG CurrentIdleState;
|
||||||
} PROCESSOR_POWER_INFORMATION, *PPROCESSOR_POWER_INFORMATION;
|
} PROCESSOR_POWER_INFORMATION, *PPROCESSOR_POWER_INFORMATION;
|
||||||
|
|
||||||
typedef struct _SYSTEM_BATTERY_STATE {
|
|
||||||
BOOLEAN AcOnLine;
|
|
||||||
BOOLEAN BatteryPresent;
|
|
||||||
BOOLEAN Charging;
|
|
||||||
BOOLEAN Discharging;
|
|
||||||
BOOLEAN Spare1[4];
|
|
||||||
ULONG MaxCapacity;
|
|
||||||
ULONG RemainingCapacity;
|
|
||||||
ULONG Rate;
|
|
||||||
ULONG EstimatedTime;
|
|
||||||
ULONG DefaultAlert1;
|
|
||||||
ULONG DefaultAlert2;
|
|
||||||
} SYSTEM_BATTERY_STATE, *PSYSTEM_BATTERY_STATE;
|
|
||||||
|
|
||||||
typedef struct _SYSTEM_POWER_CAPABILITIES {
|
|
||||||
BOOLEAN PowerButtonPresent;
|
|
||||||
BOOLEAN SleepButtonPresent;
|
|
||||||
BOOLEAN LidPresent;
|
|
||||||
BOOLEAN SystemS1;
|
|
||||||
BOOLEAN SystemS2;
|
|
||||||
BOOLEAN SystemS3;
|
|
||||||
BOOLEAN SystemS4;
|
|
||||||
BOOLEAN SystemS5;
|
|
||||||
BOOLEAN HiberFilePresent;
|
|
||||||
BOOLEAN FullWake;
|
|
||||||
BOOLEAN VideoDimPresent;
|
|
||||||
BOOLEAN ApmPresent;
|
|
||||||
BOOLEAN UpsPresent;
|
|
||||||
BOOLEAN ThermalControl;
|
|
||||||
BOOLEAN ProcessorThrottle;
|
|
||||||
UCHAR ProcessorMinThrottle;
|
|
||||||
UCHAR ProcessorMaxThrottle;
|
|
||||||
UCHAR spare2[4];
|
|
||||||
BOOLEAN DiskSpinDown;
|
|
||||||
UCHAR spare3[8];
|
|
||||||
BOOLEAN SystemBatteriesPresent;
|
|
||||||
BOOLEAN BatteriesAreShortTerm;
|
|
||||||
BATTERY_REPORTING_SCALE BatteryScale[3];
|
|
||||||
SYSTEM_POWER_STATE AcOnLineWake;
|
|
||||||
SYSTEM_POWER_STATE SoftLidWake;
|
|
||||||
SYSTEM_POWER_STATE RtcWake;
|
|
||||||
SYSTEM_POWER_STATE MinDeviceWakeState;
|
|
||||||
SYSTEM_POWER_STATE DefaultLowLatencyWake;
|
|
||||||
} SYSTEM_POWER_CAPABILITIES, *PSYSTEM_POWER_CAPABILITIES;
|
|
||||||
|
|
||||||
#pragma pack(pop)
|
#pragma pack(pop)
|
||||||
|
|
||||||
|
|
|
@ -562,26 +562,6 @@ typedef ULONG DDKAPI
|
||||||
IN ULONG Offset,
|
IN ULONG Offset,
|
||||||
IN ULONG Length);
|
IN ULONG Length);
|
||||||
|
|
||||||
typedef enum _DEVICE_POWER_STATE {
|
|
||||||
PowerDeviceUnspecified,
|
|
||||||
PowerDeviceD0,
|
|
||||||
PowerDeviceD1,
|
|
||||||
PowerDeviceD2,
|
|
||||||
PowerDeviceD3,
|
|
||||||
PowerDeviceMaximum
|
|
||||||
} DEVICE_POWER_STATE, *PDEVICE_POWER_STATE;
|
|
||||||
|
|
||||||
typedef enum _SYSTEM_POWER_STATE {
|
|
||||||
PowerSystemUnspecified,
|
|
||||||
PowerSystemWorking,
|
|
||||||
PowerSystemSleeping1,
|
|
||||||
PowerSystemSleeping2,
|
|
||||||
PowerSystemSleeping3,
|
|
||||||
PowerSystemHibernate,
|
|
||||||
PowerSystemShutdown,
|
|
||||||
PowerSystemMaximum
|
|
||||||
} SYSTEM_POWER_STATE, *PSYSTEM_POWER_STATE;
|
|
||||||
|
|
||||||
typedef union _POWER_STATE {
|
typedef union _POWER_STATE {
|
||||||
SYSTEM_POWER_STATE SystemState;
|
SYSTEM_POWER_STATE SystemState;
|
||||||
DEVICE_POWER_STATE DeviceState;
|
DEVICE_POWER_STATE DeviceState;
|
||||||
|
@ -592,17 +572,6 @@ typedef enum _POWER_STATE_TYPE {
|
||||||
DevicePowerState
|
DevicePowerState
|
||||||
} POWER_STATE_TYPE, *PPOWER_STATE_TYPE;
|
} POWER_STATE_TYPE, *PPOWER_STATE_TYPE;
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
PowerActionNone,
|
|
||||||
PowerActionReserved,
|
|
||||||
PowerActionSleep,
|
|
||||||
PowerActionHibernate,
|
|
||||||
PowerActionShutdown,
|
|
||||||
PowerActionShutdownReset,
|
|
||||||
PowerActionShutdownOff,
|
|
||||||
PowerActionWarmEject
|
|
||||||
} POWER_ACTION, *PPOWER_ACTION;
|
|
||||||
|
|
||||||
typedef struct _BUS_INTERFACE_STANDARD {
|
typedef struct _BUS_INTERFACE_STANDARD {
|
||||||
USHORT Size;
|
USHORT Size;
|
||||||
USHORT Version;
|
USHORT Version;
|
||||||
|
|
|
@ -2658,6 +2658,51 @@ typedef union _FILE_SEGMENT_ELEMENT {
|
||||||
ULONGLONG Alignment;
|
ULONGLONG Alignment;
|
||||||
}FILE_SEGMENT_ELEMENT, *PFILE_SEGMENT_ELEMENT;
|
}FILE_SEGMENT_ELEMENT, *PFILE_SEGMENT_ELEMENT;
|
||||||
|
|
||||||
|
/* JOBOBJECT_BASIC_LIMIT_INFORMATION.LimitFlags constants */
|
||||||
|
#define JOB_OBJECT_LIMIT_WORKINGSET 0x0001
|
||||||
|
#define JOB_OBJECT_LIMIT_PROCESS_TIME 0x0002
|
||||||
|
#define JOB_OBJECT_LIMIT_JOB_TIME 0x0004
|
||||||
|
#define JOB_OBJECT_LIMIT_ACTIVE_PROCESS 0x0008
|
||||||
|
#define JOB_OBJECT_LIMIT_AFFINITY 0x0010
|
||||||
|
#define JOB_OBJECT_LIMIT_PRIORITY_CLASS 0x0020
|
||||||
|
#define JOB_OBJECT_LIMIT_PRESERVE_JOB_TIME 0x0040
|
||||||
|
#define JOB_OBJECT_LIMIT_SCHEDULING_CLASS 0x0080
|
||||||
|
#define JOB_OBJECT_LIMIT_PROCESS_MEMORY 0x0100
|
||||||
|
#define JOB_OBJECT_LIMIT_JOB_MEMORY 0x0200
|
||||||
|
#define JOB_OBJECT_LIMIT_DIE_ON_UNHANDLED_EXCEPTION 0x0400
|
||||||
|
#define JOB_OBJECT_BREAKAWAY_OK 0x0800
|
||||||
|
#define JOB_OBJECT_SILENT_BREAKAWAY 0x1000
|
||||||
|
|
||||||
|
/* JOBOBJECT_BASIC_UI_RESTRICTIONS.UIRestrictionsClass constants */
|
||||||
|
#define JOB_OBJECT_UILIMIT_HANDLES 0x0001
|
||||||
|
#define JOB_OBJECT_UILIMIT_READCLIPBOARD 0x0002
|
||||||
|
#define JOB_OBJECT_UILIMIT_WRITECLIPBOARD 0x0004
|
||||||
|
#define JOB_OBJECT_UILIMIT_SYSTEMPARAMETERS 0x0008
|
||||||
|
#define JOB_OBJECT_UILIMIT_DISPLAYSETTINGS 0x0010
|
||||||
|
#define JOB_OBJECT_UILIMIT_GLOBALATOMS 0x0020
|
||||||
|
#define JOB_OBJECT_UILIMIT_DESKTOP 0x0040
|
||||||
|
#define JOB_OBJECT_UILIMIT_EXITWINDOWS 0x0080
|
||||||
|
|
||||||
|
/* JOBOBJECT_SECURITY_LIMIT_INFORMATION.SecurityLimitFlags constants */
|
||||||
|
#define JOB_OBJECT_SECURITY_NO_ADMIN 0x0001
|
||||||
|
#define JOB_OBJECT_SECURITY_RESTRICTED_TOKEN 0x0002
|
||||||
|
#define JOB_OBJECT_SECURITY_ONLY_TOKEN 0x0004
|
||||||
|
#define JOB_OBJECT_SECURITY_FILTER_TOKENS 0x0008
|
||||||
|
|
||||||
|
/* JOBOBJECT_END_OF_JOB_TIME_INFORMATION.EndOfJobTimeAction constants */
|
||||||
|
#define JOB_OBJECT_TERMINATE_AT_END_OF_JOB 0
|
||||||
|
#define JOB_OBJECT_POST_AT_END_OF_JOB 1
|
||||||
|
|
||||||
|
#define JOB_OBJECT_MSG_END_OF_JOB_TIME 1
|
||||||
|
#define JOB_OBJECT_MSG_END_OF_PROCESS_TIME 2
|
||||||
|
#define JOB_OBJECT_MSG_ACTIVE_PROCESS_LIMIT 3
|
||||||
|
#define JOB_OBJECT_MSG_ACTIVE_PROCESS_ZERO 4
|
||||||
|
#define JOB_OBJECT_MSG_NEW_PROCESS 6
|
||||||
|
#define JOB_OBJECT_MSG_EXIT_PROCESS 7
|
||||||
|
#define JOB_OBJECT_MSG_ABNORMAL_EXIT_PROCESS 8
|
||||||
|
#define JOB_OBJECT_MSG_PROCESS_MEMORY_LIMIT 9
|
||||||
|
#define JOB_OBJECT_MSG_JOB_MEMORY_LIMIT 10
|
||||||
|
|
||||||
typedef enum _JOBOBJECTINFOCLASS {
|
typedef enum _JOBOBJECTINFOCLASS {
|
||||||
JobObjectBasicAccountingInformation = 1,
|
JobObjectBasicAccountingInformation = 1,
|
||||||
JobObjectBasicLimitInformation,
|
JobObjectBasicLimitInformation,
|
||||||
|
@ -2730,6 +2775,214 @@ typedef struct _JOBOBJECT_JOBSET_INFORMATION {
|
||||||
DWORD MemberLevel;
|
DWORD MemberLevel;
|
||||||
} JOBOBJECT_JOBSET_INFORMATION,*PJOBOBJECT_JOBSET_INFORMATION;
|
} JOBOBJECT_JOBSET_INFORMATION,*PJOBOBJECT_JOBSET_INFORMATION;
|
||||||
|
|
||||||
|
/* Fixme: Making these defines conditional on WINVER will break ddk includes */
|
||||||
|
#if 1 /* (WINVER >= 0x0500) */
|
||||||
|
#include <pshpack4.h>
|
||||||
|
|
||||||
|
#define ES_SYSTEM_REQUIRED 0x00000001
|
||||||
|
#define ES_DISPLAY_REQUIRED 0x00000002
|
||||||
|
#define ES_USER_PRESENT 0x00000004
|
||||||
|
#define ES_CONTINUOUS 0x80000000
|
||||||
|
|
||||||
|
typedef enum _LATENCY_TIME {
|
||||||
|
LT_DONT_CARE,
|
||||||
|
LT_LOWEST_LATENCY
|
||||||
|
} LATENCY_TIME, *PLATENCY_TIME;
|
||||||
|
|
||||||
|
typedef enum _SYSTEM_POWER_STATE {
|
||||||
|
PowerSystemUnspecified,
|
||||||
|
PowerSystemWorking,
|
||||||
|
PowerSystemSleeping1,
|
||||||
|
PowerSystemSleeping2,
|
||||||
|
PowerSystemSleeping3,
|
||||||
|
PowerSystemHibernate,
|
||||||
|
PowerSystemShutdown,
|
||||||
|
PowerSystemMaximum
|
||||||
|
} SYSTEM_POWER_STATE, *PSYSTEM_POWER_STATE;
|
||||||
|
#define POWER_SYSTEM_MAXIMUM PowerSystemMaximum
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
PowerActionNone,
|
||||||
|
PowerActionReserved,
|
||||||
|
PowerActionSleep,
|
||||||
|
PowerActionHibernate,
|
||||||
|
PowerActionShutdown,
|
||||||
|
PowerActionShutdownReset,
|
||||||
|
PowerActionShutdownOff,
|
||||||
|
PowerActionWarmEject
|
||||||
|
} POWER_ACTION, *PPOWER_ACTION;
|
||||||
|
|
||||||
|
typedef enum _DEVICE_POWER_STATE {
|
||||||
|
PowerDeviceUnspecified,
|
||||||
|
PowerDeviceD0,
|
||||||
|
PowerDeviceD1,
|
||||||
|
PowerDeviceD2,
|
||||||
|
PowerDeviceD3,
|
||||||
|
PowerDeviceMaximum
|
||||||
|
} DEVICE_POWER_STATE, *PDEVICE_POWER_STATE;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
DWORD Granularity;
|
||||||
|
DWORD Capacity;
|
||||||
|
} BATTERY_REPORTING_SCALE, *PBATTERY_REPORTING_SCALE;
|
||||||
|
|
||||||
|
typedef struct _POWER_ACTION_POLICY {
|
||||||
|
POWER_ACTION Action;
|
||||||
|
ULONG Flags;
|
||||||
|
ULONG EventCode;
|
||||||
|
} POWER_ACTION_POLICY, *PPOWER_ACTION_POLICY;
|
||||||
|
|
||||||
|
/* POWER_ACTION_POLICY.Flags constants */
|
||||||
|
#define POWER_ACTION_QUERY_ALLOWED 0x00000001
|
||||||
|
#define POWER_ACTION_UI_ALLOWED 0x00000002
|
||||||
|
#define POWER_ACTION_OVERRIDE_APPS 0x00000004
|
||||||
|
#define POWER_ACTION_LIGHTEST_FIRST 0x10000000
|
||||||
|
#define POWER_ACTION_LOCK_CONSOLE 0x20000000
|
||||||
|
#define POWER_ACTION_DISABLE_WAKES 0x40000000
|
||||||
|
#define POWER_ACTION_CRITICAL 0x80000000
|
||||||
|
|
||||||
|
/* POWER_ACTION_POLICY.EventCode constants */
|
||||||
|
#define POWER_LEVEL_USER_NOTIFY_TEXT 0x00000001
|
||||||
|
#define POWER_LEVEL_USER_NOTIFY_SOUND 0x00000002
|
||||||
|
#define POWER_LEVEL_USER_NOTIFY_EXEC 0x00000004
|
||||||
|
#define POWER_USER_NOTIFY_BUTTON 0x00000008
|
||||||
|
#define POWER_USER_NOTIFY_SHUTDOWN 0x00000010
|
||||||
|
#define POWER_FORCE_TRIGGER_RESET 0x80000000
|
||||||
|
|
||||||
|
#define DISCHARGE_POLICY_CRITICAL 0
|
||||||
|
#define DISCHARGE_POLICY_LOW 1
|
||||||
|
#define NUM_DISCHARGE_POLICIES 4
|
||||||
|
|
||||||
|
#define PO_THROTTLE_NONE 0
|
||||||
|
#define PO_THROTTLE_CONSTANT 1
|
||||||
|
#define PO_THROTTLE_DEGRADE 2
|
||||||
|
#define PO_THROTTLE_ADAPTIVE 3
|
||||||
|
#define PO_THROTTLE_MAXIMUM 4
|
||||||
|
|
||||||
|
typedef struct _SYSTEM_POWER_LEVEL {
|
||||||
|
BOOLEAN Enable;
|
||||||
|
UCHAR Spare[3];
|
||||||
|
ULONG BatteryLevel;
|
||||||
|
POWER_ACTION_POLICY PowerPolicy;
|
||||||
|
SYSTEM_POWER_STATE MinSystemState;
|
||||||
|
} SYSTEM_POWER_LEVEL, *PSYSTEM_POWER_LEVEL;
|
||||||
|
|
||||||
|
typedef struct _SYSTEM_POWER_POLICY {
|
||||||
|
ULONG Revision;
|
||||||
|
POWER_ACTION_POLICY PowerButton;
|
||||||
|
POWER_ACTION_POLICY SleepButton;
|
||||||
|
POWER_ACTION_POLICY LidClose;
|
||||||
|
SYSTEM_POWER_STATE LidOpenWake;
|
||||||
|
ULONG Reserved;
|
||||||
|
POWER_ACTION_POLICY Idle;
|
||||||
|
ULONG IdleTimeout;
|
||||||
|
UCHAR IdleSensitivity;
|
||||||
|
UCHAR DynamicThrottle;
|
||||||
|
UCHAR Spare2[2];
|
||||||
|
SYSTEM_POWER_STATE MinSleep;
|
||||||
|
SYSTEM_POWER_STATE MaxSleep;
|
||||||
|
SYSTEM_POWER_STATE ReducedLatencySleep;
|
||||||
|
ULONG WinLogonFlags;
|
||||||
|
ULONG Spare3;
|
||||||
|
ULONG DozeS4Timeout;
|
||||||
|
ULONG BroadcastCapacityResolution;
|
||||||
|
SYSTEM_POWER_LEVEL DischargePolicy[NUM_DISCHARGE_POLICIES];
|
||||||
|
ULONG VideoTimeout;
|
||||||
|
BOOLEAN VideoDimDisplay;
|
||||||
|
ULONG VideoReserved[3];
|
||||||
|
ULONG SpindownTimeout;
|
||||||
|
BOOLEAN OptimizeForPower;
|
||||||
|
UCHAR FanThrottleTolerance;
|
||||||
|
UCHAR ForcedThrottle;
|
||||||
|
UCHAR MinThrottle;
|
||||||
|
POWER_ACTION_POLICY OverThrottled;
|
||||||
|
} SYSTEM_POWER_POLICY, *PSYSTEM_POWER_POLICY;
|
||||||
|
|
||||||
|
typedef struct _SYSTEM_POWER_CAPABILITIES {
|
||||||
|
BOOLEAN PowerButtonPresent;
|
||||||
|
BOOLEAN SleepButtonPresent;
|
||||||
|
BOOLEAN LidPresent;
|
||||||
|
BOOLEAN SystemS1;
|
||||||
|
BOOLEAN SystemS2;
|
||||||
|
BOOLEAN SystemS3;
|
||||||
|
BOOLEAN SystemS4;
|
||||||
|
BOOLEAN SystemS5;
|
||||||
|
BOOLEAN HiberFilePresent;
|
||||||
|
BOOLEAN FullWake;
|
||||||
|
BOOLEAN VideoDimPresent;
|
||||||
|
BOOLEAN ApmPresent;
|
||||||
|
BOOLEAN UpsPresent;
|
||||||
|
BOOLEAN ThermalControl;
|
||||||
|
BOOLEAN ProcessorThrottle;
|
||||||
|
UCHAR ProcessorMinThrottle;
|
||||||
|
UCHAR ProcessorMaxThrottle;
|
||||||
|
UCHAR spare2[4];
|
||||||
|
BOOLEAN DiskSpinDown;
|
||||||
|
UCHAR spare3[8];
|
||||||
|
BOOLEAN SystemBatteriesPresent;
|
||||||
|
BOOLEAN BatteriesAreShortTerm;
|
||||||
|
BATTERY_REPORTING_SCALE BatteryScale[3];
|
||||||
|
SYSTEM_POWER_STATE AcOnLineWake;
|
||||||
|
SYSTEM_POWER_STATE SoftLidWake;
|
||||||
|
SYSTEM_POWER_STATE RtcWake;
|
||||||
|
SYSTEM_POWER_STATE MinDeviceWakeState;
|
||||||
|
SYSTEM_POWER_STATE DefaultLowLatencyWake;
|
||||||
|
} SYSTEM_POWER_CAPABILITIES, *PSYSTEM_POWER_CAPABILITIES;
|
||||||
|
|
||||||
|
typedef struct _SYSTEM_BATTERY_STATE {
|
||||||
|
BOOLEAN AcOnLine;
|
||||||
|
BOOLEAN BatteryPresent;
|
||||||
|
BOOLEAN Charging;
|
||||||
|
BOOLEAN Discharging;
|
||||||
|
BOOLEAN Spare1[4];
|
||||||
|
ULONG MaxCapacity;
|
||||||
|
ULONG RemainingCapacity;
|
||||||
|
ULONG Rate;
|
||||||
|
ULONG EstimatedTime;
|
||||||
|
ULONG DefaultAlert1;
|
||||||
|
ULONG DefaultAlert2;
|
||||||
|
} SYSTEM_BATTERY_STATE, *PSYSTEM_BATTERY_STATE;
|
||||||
|
|
||||||
|
#if 1 /* (WIN32_WINNT >= 0x0500) */
|
||||||
|
typedef struct _SYSTEM_POWER_INFORMATION {
|
||||||
|
ULONG MaxIdlenessAllowed;
|
||||||
|
ULONG Idleness;
|
||||||
|
ULONG TimeRemaining;
|
||||||
|
UCHAR CoolingMode;
|
||||||
|
} SYSTEM_POWER_INFORMATION, *PSYSTEM_POWER_INFORMATION;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
typedef struct _PROCESSOR_POWER_POLICY_INFO {
|
||||||
|
ULONG TimeCheck;
|
||||||
|
ULONG DemoteLimit;
|
||||||
|
ULONG PromoteLimit;
|
||||||
|
UCHAR DemotePercent;
|
||||||
|
UCHAR PromotePercent;
|
||||||
|
UCHAR Spare[2];
|
||||||
|
ULONG AllowDemotion : 1;
|
||||||
|
ULONG AllowPromotion : 1;
|
||||||
|
ULONG Reserved : 30;
|
||||||
|
} PROCESSOR_POWER_POLICY_INFO, *PPROCESSOR_POWER_POLICY_INFO;
|
||||||
|
typedef struct _PROCESSOR_POWER_POLICY {
|
||||||
|
ULONG Revision;
|
||||||
|
UCHAR DynamicThrottle;
|
||||||
|
UCHAR Spare[3];
|
||||||
|
ULONG Reserved;
|
||||||
|
ULONG PolicyCount;
|
||||||
|
PROCESSOR_POWER_POLICY_INFO Policy[3];
|
||||||
|
} PROCESSOR_POWER_POLICY, *PPROCESSOR_POWER_POLICY;
|
||||||
|
typedef struct _ADMINISTRATOR_POWER_POLICY {
|
||||||
|
SYSTEM_POWER_STATE MinSleep;
|
||||||
|
SYSTEM_POWER_STATE MaxSleep;
|
||||||
|
ULONG MinVideoTimeout;
|
||||||
|
ULONG MaxVideoTimeout;
|
||||||
|
ULONG MinSpindownTimeout;
|
||||||
|
ULONG MaxSpindownTimeout;
|
||||||
|
} ADMINISTRATOR_POWER_POLICY, *PADMINISTRATOR_POWER_POLICY;
|
||||||
|
#include <poppack.h>
|
||||||
|
#endif /* WINVER >= 0x0500 */
|
||||||
|
|
||||||
|
|
||||||
#ifdef UNICODE
|
#ifdef UNICODE
|
||||||
typedef OSVERSIONINFOW OSVERSIONINFO,*POSVERSIONINFO,*LPOSVERSIONINFO;
|
typedef OSVERSIONINFOW OSVERSIONINFO,*POSVERSIONINFO,*LPOSVERSIONINFO;
|
||||||
typedef OSVERSIONINFOEXW OSVERSIONINFOEX,*POSVERSIONINFOEX,*LPOSVERSIONINFOEX;
|
typedef OSVERSIONINFOEXW OSVERSIONINFOEX,*POSVERSIONINFOEX,*LPOSVERSIONINFOEX;
|
||||||
|
@ -2787,7 +3040,8 @@ extern PVOID GetFiberData(void);
|
||||||
|
|
||||||
#endif /* __GNUC__ */
|
#endif /* __GNUC__ */
|
||||||
|
|
||||||
#endif
|
#endif /* RC_INVOKED */
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue