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.

82 lines
1.1 KiB

  1. /*++
  2. Module Name:
  3. apmp.h
  4. Abstract:
  5. Author:
  6. Revision History:
  7. --*/
  8. //
  9. // APM Bios interface information
  10. //
  11. typedef struct _APM_CONNECT {
  12. KSPIN_LOCK CallLock;
  13. ULONG Code16BitOffset;
  14. USHORT Selector[4];
  15. PVOID VirtualAddress[4];
  16. } APM_CONNECT, *PAPM_CONNTECT;
  17. ///
  18. // Apm.c
  19. //
  20. NTSTATUS
  21. ApmInitializeConnection (
  22. VOID
  23. );
  24. ULONG
  25. ApmCallBios (
  26. IN ULONG ApmFunctionCode,
  27. IN OUT PULONG Ebx,
  28. IN OUT PULONG Ecx
  29. );
  30. VOID
  31. ApmGetBatteryStatus (
  32. );
  33. #define APM_DO_NOTHING 0
  34. #define APM_DO_SUSPEND 1
  35. #define APM_DO_STANDBY 2
  36. #define APM_DO_FIXCLOCK 3
  37. #define APM_DO_NOTIFY 4
  38. #define APM_DO_CRITICAL_SUSPEND 5
  39. ULONG
  40. ApmCheckForEvent (
  41. VOID
  42. );
  43. NTSTATUS
  44. ApmSuspendSystem (
  45. VOID
  46. );
  47. NTSTATUS
  48. ApmStandBySystem (
  49. VOID
  50. );
  51. VOID
  52. ApmTurnOffSystem (
  53. VOID
  54. );
  55. NTSTATUS
  56. ApmFunction (
  57. IN ULONG ApmFunctionCode,
  58. IN OUT PULONG Ebx,
  59. IN OUT PULONG Ecx
  60. );