DxeCpuPolicyUpdateLib.h 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. /** @file
  2. Copyright (c) 2020, Intel Corporation. All rights reserved.<BR>
  3. SPDX-License-Identifier: BSD-2-Clause-Patent
  4. **/
  5. #ifndef _DXE_CPU_POLICY_UPDATE_LIB_H_
  6. #define _DXE_CPU_POLICY_UPDATE_LIB_H_
  7. #include <PiDxe.h>
  8. #include <PchAccess.h>
  9. #include <Library/DebugLib.h>
  10. #include <Library/BaseMemoryLib.h>
  11. #include <Library/UefiRuntimeServicesTableLib.h>
  12. #include <Library/UefiBootServicesTableLib.h>
  13. #include <Protocol/CpuPolicyProtocol.h>
  14. /**
  15. This function prints the CPU DXE phase policy.
  16. @param[in] DxeCpuPolicy - CPU DXE Policy protocol
  17. **/
  18. VOID
  19. CpuDxePrintPolicyProtocol (
  20. IN DXE_CPU_POLICY_PROTOCOL *DxeCpuPolicy
  21. );
  22. /**
  23. Routine Description:
  24. This function updates Dxe Cpu Policy Protocol
  25. Arguments:
  26. @param[in] DxeCpuPolicy The Cpu Policy protocol instance
  27. Returns:
  28. @retval EFI_SUCCESS Initialization complete.
  29. @retval EFI_UNSUPPORTED The chipset is unsupported by this driver.
  30. @retval EFI_OUT_OF_RESOURCES Do not have enough resources to initialize the driver.
  31. @retval EFI_DEVICE_ERROR Device error, driver exits abnormally.
  32. **/
  33. EFI_STATUS
  34. EFIAPI
  35. UpdateDxeSiCpuPolicy (
  36. IN OUT DXE_CPU_POLICY_PROTOCOL *DxeCpuPolicy
  37. );
  38. /**
  39. CpuInstallPolicyProtocol installs CPU Policy.
  40. While installed, RC assumes the Policy is ready and finalized. So please update and override
  41. any setting before calling this function.
  42. @param[in] ImageHandle Image handle of this driver.
  43. @param[in] DxeCpuPolicy The pointer to CPU Policy Protocol instance
  44. @retval EFI_SUCCESS The policy is installed.
  45. @retval EFI_OUT_OF_RESOURCES Insufficient resources to create buffer
  46. **/
  47. EFI_STATUS
  48. EFIAPI
  49. CpuInstallPolicyProtocol (
  50. IN EFI_HANDLE ImageHandle,
  51. IN DXE_CPU_POLICY_PROTOCOL *DxeCpuPolicy
  52. );
  53. #endif