DxeSaPolicyInit.h 2.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /** @file
  2. Header file for the SaPolicyInitDxe Driver.
  3. Copyright (c) 2019, Intel Corporation. All rights reserved.<BR>
  4. SPDX-License-Identifier: BSD-2-Clause-Patent
  5. **/
  6. #ifndef _SA_POLICY_INIT_DXE_H_
  7. #define _SA_POLICY_INIT_DXE_H_
  8. #include <Library/BaseMemoryLib.h>
  9. #include <Library/MemoryAllocationLib.h>
  10. #include <Library/DebugLib.h>
  11. #include <Library/UefiBootServicesTableLib.h>
  12. #include <Protocol/SaPolicy.h>
  13. #include <Library/DxeSaPolicyLib.h>
  14. #include <SaAccess.h>
  15. /**
  16. <b>SA DXE Policy Driver Entry Point</b> \n
  17. - <b>Introduction</b> \n
  18. System Agent DXE drivers behavior can be controlled by platform policy without modifying reference code directly.
  19. Platform policy Protocol is initialized with default settings in this funciton.
  20. This policy Protocol has to be initialized prior to System Agent initialization DXE drivers execution.
  21. - @pre
  22. - Runtime variable service should be ready if policy initialization required.
  23. - @result
  24. SA_POLICY_PROTOCOL will be installed successfully and ready for System Agent reference code use.
  25. - <b>Porting Recommendations</b> \n
  26. Policy should be initialized basing on platform design or user selection (like BIOS Setup Menu)
  27. @param[in] ImageHandle - Image handle of this driver.
  28. @retval EFI_SUCCESS Initialization complete.
  29. @exception 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. SaPolicyInitDxe (
  36. IN EFI_HANDLE ImageHandle
  37. );
  38. /**
  39. Get data for platform policy from setup options.
  40. @param[in] SaPolicy The pointer to get SA Policy protocol instance
  41. @retval EFI_SUCCESS Operation success.
  42. **/
  43. EFI_STATUS
  44. EFIAPI
  45. UpdateDxeSaPolicy (
  46. IN OUT SA_POLICY_PROTOCOL *SaPolicy
  47. );
  48. #endif