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.

234 lines
4.8 KiB

  1. /*++
  2. Copyright (c) 1991 Microsoft Corporation
  3. Module Name:
  4. ixdat.c
  5. Abstract:
  6. Declares various data which is initialize data, or pagable data.
  7. Author:
  8. Environment:
  9. Kernel mode only.
  10. Revision History:
  11. --*/
  12. #include "halp.h"
  13. #ifdef ALLOC_DATA_PRAGMA
  14. #pragma data_seg("INIT")
  15. #endif
  16. //
  17. // The following data is only valid during system initialiation
  18. // and the memory will be re-claimed by the system afterwards
  19. //
  20. ADDRESS_USAGE HalpDefaultPcIoSpace = {
  21. NULL, CmResourceTypePort, DeviceUsage,
  22. {
  23. 0x000, 0x20, // ISA DMA
  24. 0x0C0, 0x20, // ISA DMA
  25. 0x080, 0x10, // DMA
  26. 0x020, 0x2, // PIC
  27. 0x0A0, 0x2, // Cascaded PIC
  28. 0x040, 0x4, // Timer1, Referesh, Speaker, Control Word
  29. 0x048, 0x4, // Timer2, Failsafe
  30. #if 0 // HACKHACK Remove for now since Intelille mouse software claims it.
  31. 0x061, 0x1, // NMI (system control port B)
  32. #endif
  33. 0x092, 0x1, // system control port A
  34. #ifndef ACPI_HAL
  35. 0x070, 0x2, // Cmos/NMI enable
  36. #endif
  37. #ifdef MCA
  38. 0x074, 0x3, // Extended CMOS
  39. 0x090, 0x2, // Arbritration Control Port, Card Select Feedback
  40. 0x093, 0x2, // Reserved, System board setup
  41. 0x096, 0x2, // POS channel select
  42. #endif
  43. 0x0F0, 0x10, // coprocessor ports
  44. #ifndef ACPI_HAL
  45. 0xCF8, 0x8, // PCI Config Space Access Pair
  46. #endif
  47. 0,0
  48. }
  49. };
  50. ADDRESS_USAGE HalpEisaIoSpace = {
  51. NULL, CmResourceTypePort, DeviceUsage,
  52. {
  53. 0x0D0, 0x10, // DMA
  54. 0x400, 0x10, // DMA
  55. 0x480, 0x10, // DMA
  56. 0x4C2, 0xE, // DMA
  57. 0x4D4, 0x2C, // DMA
  58. 0x461, 0x2, // Extended NMI
  59. 0x464, 0x2, // Last Eisa Bus Muster granted
  60. 0x4D0, 0x2, // edge/level control registers
  61. 0xC84, 0x1, // System board enable
  62. 0, 0
  63. }
  64. };
  65. #ifndef ACPI_HAL
  66. ADDRESS_USAGE HalpDetectedROM = {
  67. NULL,
  68. CmResourceTypeMemory,
  69. InternalUsage | RomResource,
  70. {
  71. 0,0, // 32 ROM blocks, get initialized in ixusage.c
  72. 0,0,
  73. 0,0,
  74. 0,0,
  75. 0,0,
  76. 0,0,
  77. 0,0,
  78. 0,0,
  79. 0,0,
  80. 0,0,
  81. 0,0,
  82. 0,0,
  83. 0,0,
  84. 0,0,
  85. 0,0,
  86. 0,0,
  87. 0,0,
  88. 0,0,
  89. 0,0,
  90. 0,0,
  91. 0,0,
  92. 0,0,
  93. 0,0,
  94. 0,0,
  95. 0,0,
  96. 0,0,
  97. 0,0,
  98. 0,0,
  99. 0,0,
  100. 0,0,
  101. 0,0,
  102. 0,0,
  103. 0,0
  104. }
  105. };
  106. #endif
  107. //
  108. // Strings used for boot.ini options
  109. // from mphal.c
  110. //
  111. UCHAR HalpSzBreak[] = "BREAK";
  112. UCHAR HalpSzPciLock[] = "PCILOCK";
  113. //
  114. // From ixcmos.asm
  115. //
  116. UCHAR HalpSerialLen = 0;
  117. UCHAR HalpSerialNumber[31] = {0};
  118. //
  119. // From usage.c
  120. //
  121. WCHAR HalpSzSystem[] = L"\\Registry\\Machine\\Hardware\\Description\\System";
  122. WCHAR HalpSzSerialNumber[] = L"Serial Number";
  123. ADDRESS_USAGE *HalpAddressUsageList = NULL;
  124. //
  125. // Misc hal stuff in the registry
  126. //
  127. WCHAR rgzHalClassName[] = L"Hardware Abstraction Layer";
  128. //
  129. // From ixpcibus.c
  130. //
  131. WCHAR rgzMultiFunctionAdapter[] = L"\\Registry\\Machine\\Hardware\\Description\\System\\MultifunctionAdapter";
  132. WCHAR rgzConfigurationData[] = L"Configuration Data";
  133. WCHAR rgzIdentifier[] = L"Identifier";
  134. WCHAR rgzPCIIdentifier[] = L"PCI";
  135. WCHAR rgzPCICardList[] = L"\\Registry\\Machine\\System\\CurrentControlSet\\Control\\PnP\\PCI\\CardList";
  136. //
  137. // From ixpcibrd.c
  138. //
  139. WCHAR rgzReservedResources[] = L"\\Registry\\Machine\\System\\CurrentControlSet\\Control\\SystemResources\\ReservedResources";
  140. //
  141. // From ixinfo.c
  142. //
  143. WCHAR rgzSuspendCallbackName[] = L"\\Callback\\SuspendHibernateSystem";
  144. //
  145. // From ixmca.c
  146. //
  147. UCHAR MsgMCEPending[] = MSG_MCE_PENDING;
  148. WCHAR rgzSessionManager[] = L"Session Manager";
  149. WCHAR rgzEnableMCE[] = L"EnableMCE";
  150. WCHAR rgzEnableMCA[] = L"EnableMCA";
  151. WCHAR rgzEnableCMC[] = L"EnableCMC";
  152. WCHAR rgzNoMCABugCheck[] = L"NoMCABugCheck";
  153. #ifdef ALLOC_DATA_PRAGMA
  154. #pragma data_seg()
  155. #endif
  156. UCHAR HalpGenuineIntel[]= "GenuineIntel";
  157. UCHAR HalpAuthenticAMD[]= "AuthenticAMD";
  158. ULONG HalpFeatureBits = 0;
  159. //
  160. // Stuff that we only need while we
  161. // sleep or hibernate.
  162. //
  163. MOTHERBOARD_CONTEXT HalpMotherboardState = {0};
  164. //
  165. // PAGELK handle
  166. //
  167. PVOID HalpSleepPageLock = NULL;
  168. PVOID HalpSleepPage16Lock = NULL;
  169. USHORT HalpPciIrqMask = 0;
  170. USHORT HalpEisaIrqMask = 0;
  171. USHORT HalpEisaIrqIgnore = 0x1000;
  172. BOOLEAN HalpDisableHibernate = FALSE;
  173. //
  174. // Timer watchdog variables
  175. //
  176. ULONG HalpTimerWatchdogEnabled = 0;
  177. ULONG HalpTimerWatchdogStorageOverflow = 0;
  178. PVOID HalpTimerWatchdogCurFrame = NULL;
  179. PVOID HalpTimerWatchdogLastFrame = NULL;
  180. PCHAR HalpTimerWatchdogStorage = NULL;