SecretDxe.c 740 B

123456789101112131415161718192021222324252627
  1. /** @file
  2. Confidential Computing Secret configuration table constructor
  3. Copyright (C) 2020 James Bottomley, IBM Corporation.
  4. SPDX-License-Identifier: BSD-2-Clause-Patent
  5. **/
  6. #include <PiDxe.h>
  7. #include <Library/UefiBootServicesTableLib.h>
  8. #include <Guid/ConfidentialComputingSecret.h>
  9. STATIC CONFIDENTIAL_COMPUTING_SECRET_LOCATION mSecretDxeTable = {
  10. FixedPcdGet32 (PcdSevLaunchSecretBase),
  11. FixedPcdGet32 (PcdSevLaunchSecretSize),
  12. };
  13. EFI_STATUS
  14. EFIAPI
  15. InitializeSecretDxe (
  16. IN EFI_HANDLE ImageHandle,
  17. IN EFI_SYSTEM_TABLE *SystemTable
  18. )
  19. {
  20. return gBS->InstallConfigurationTable (
  21. &gConfidentialComputingSecretGuid,
  22. &mSecretDxeTable
  23. );
  24. }