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.

146 lines
3.7 KiB

  1. /*++
  2. Copyright (c) 1998 Intel Corporation
  3. Module Name:
  4. data.c
  5. Abstract:
  6. EFI library global data
  7. Revision History
  8. --*/
  9. #include "lib.h"
  10. /*
  11. * LibInitialized - TRUE once InitializeLib() is called for the first time
  12. */
  13. BOOLEAN LibInitialized = FALSE;
  14. /*
  15. * ST - pointer to the EFI system table
  16. */
  17. EFI_SYSTEM_TABLE *ST;
  18. /*
  19. * BS - pointer to the boot services table
  20. */
  21. EFI_BOOT_SERVICES *BS;
  22. /*
  23. * Default pool allocation type
  24. */
  25. EFI_MEMORY_TYPE PoolAllocationType = EfiBootServicesData;
  26. /*
  27. * Unicode collation functions that are in use
  28. */
  29. EFI_UNICODE_COLLATION_INTERFACE LibStubUnicodeInterface = {
  30. LibStubStriCmp,
  31. LibStubMetaiMatch,
  32. LibStubStrLwrUpr,
  33. LibStubStrLwrUpr,
  34. NULL, /* FatToStr */
  35. NULL, /* StrToFat */
  36. NULL /* SupportedLanguages */
  37. };
  38. EFI_UNICODE_COLLATION_INTERFACE *UnicodeInterface = &LibStubUnicodeInterface;
  39. /*
  40. * Root device path
  41. */
  42. EFI_DEVICE_PATH RootDevicePath[] = {
  43. END_DEVICE_PATH_TYPE, END_ENTIRE_DEVICE_PATH_SUBTYPE, END_DEVICE_PATH_LENGTH, 0
  44. };
  45. EFI_DEVICE_PATH EndDevicePath[] = {
  46. END_DEVICE_PATH_TYPE, END_ENTIRE_DEVICE_PATH_SUBTYPE, END_DEVICE_PATH_LENGTH, 0
  47. };
  48. EFI_DEVICE_PATH EndInstanceDevicePath[] = {
  49. END_DEVICE_PATH_TYPE, END_INSTANCE_DEVICE_PATH_SUBTYPE, END_DEVICE_PATH_LENGTH, 0
  50. };
  51. /*
  52. * EFI IDs
  53. */
  54. EFI_GUID EfiGlobalVariable = EFI_GLOBAL_VARIABLE;
  55. EFI_GUID NullGuid = { 0,0,0,0,0,0,0,0,0,0,0 };
  56. /*
  57. * Protocol IDs
  58. */
  59. EFI_GUID DevicePathProtocol = DEVICE_PATH_PROTOCOL;
  60. EFI_GUID LoadedImageProtocol = LOADED_IMAGE_PROTOCOL;
  61. EFI_GUID TextInProtocol = SIMPLE_TEXT_INPUT_PROTOCOL;
  62. EFI_GUID TextOutProtocol = SIMPLE_TEXT_OUTPUT_PROTOCOL;
  63. EFI_GUID BlockIoProtocol = BLOCK_IO_PROTOCOL;
  64. EFI_GUID DiskIoProtocol = DISK_IO_PROTOCOL;
  65. EFI_GUID FileSystemProtocol = SIMPLE_FILE_SYSTEM_PROTOCOL;
  66. EFI_GUID LoadFileProtocol = LOAD_FILE_PROTOCOL;
  67. EFI_GUID DeviceIoProtocol = DEVICE_IO_PROTOCOL;
  68. EFI_GUID UnicodeCollationProtocol = UNICODE_COLLATION_PROTOCOL;
  69. EFI_GUID SerialIoProtocol = SERIAL_IO_PROTOCOL;
  70. EFI_GUID SimpleNetworkProtocol = EFI_SIMPLE_NETWORK_PROTOCOL;
  71. EFI_GUID PxeBaseCodeProtocol = EFI_PXE_BASE_CODE_PROTOCOL;
  72. EFI_GUID PxeCallbackProtocol = EFI_PXE_BASE_CODE_CALLBACK_PROTOCOL;
  73. EFI_GUID NetworkInterfaceIdentifierProtocol = EFI_NETWORK_INTERFACE_IDENTIFIER_PROTOCOL;
  74. /*
  75. * File system information IDs
  76. */
  77. EFI_GUID GenericFileInfo = EFI_FILE_INFO_ID;
  78. EFI_GUID FileSystemInfo = EFI_FILE_SYSTEM_INFO_ID;
  79. EFI_GUID FileSystemVolumeLabelInfo = EFI_FILE_SYSTEM_VOLUME_LABEL_INFO_ID;
  80. /*
  81. * Reference implementation public protocol IDs
  82. */
  83. EFI_GUID VariableStoreProtocol = VARIABLE_STORE_PROTOCOL;
  84. EFI_GUID LegacyBootProtocol = LEGACY_BOOT_PROTOCOL;
  85. EFI_GUID VgaClassProtocol = VGA_CLASS_DRIVER_PROTOCOL;
  86. EFI_GUID InternalLoadProtocol = INTERNAL_LOAD_PROTOCOL;
  87. EFI_GUID TextOutSpliterProtocol = TEXT_OUT_SPLITER_PROTOCOL;
  88. EFI_GUID ErrorOutSpliterProtocol = ERROR_OUT_SPLITER_PROTOCOL;
  89. EFI_GUID TextInSpliterProtocol = TEXT_IN_SPLITER_PROTOCOL;
  90. /*
  91. * Device path media protocol IDs
  92. */
  93. EFI_GUID PcAnsiProtocol = DEVICE_PATH_MESSAGING_PC_ANSI;
  94. EFI_GUID Vt100Protocol = DEVICE_PATH_MESSAGING_VT_100;
  95. /*
  96. * Reference implementation Vendor Device Path Guids
  97. */
  98. EFI_GUID UnknownDevice = UNKNOWN_DEVICE_GUID;
  99. /*
  100. * Configuration Table GUIDs
  101. */
  102. EFI_GUID MpsTableGuid = MPS_TABLE_GUID;
  103. EFI_GUID AcpiTableGuid = ACPI_TABLE_GUID;
  104. EFI_GUID SMBIOSTableGuid = SMBIOS_TABLE_GUID;
  105. EFI_GUID SalSystemTableGuid = SAL_SYSTEM_TABLE_GUID;