TianoCore EDK2 master
Loading...
Searching...
No Matches
AmdSvsmLibNull.c File Reference
#include <Base.h>
#include <Uefi.h>
#include <Library/AmdSvsmLib.h>

Go to the source code of this file.

Functions

BOOLEAN EFIAPI AmdSvsmIsSvsmPresent (VOID)
 
UINT8 EFIAPI AmdSvsmSnpGetVmpl (VOID)
 
UINT64 EFIAPI AmdSvsmSnpGetCaa (VOID)
 
VOID EFIAPI AmdSvsmSnpPvalidate (IN SNP_PAGE_STATE_CHANGE_INFO *Info)
 
EFI_STATUS EFIAPI AmdSvsmSnpVmsaRmpAdjust (IN SEV_ES_SAVE_AREA *Vmsa, IN UINT32 ApicId, IN BOOLEAN SetVmsa)
 

Detailed Description

AmdSvsm Base Support Library.

Copyright (C) 2024, Advanced Micro Devices, Inc. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file AmdSvsmLibNull.c.

Function Documentation

◆ AmdSvsmIsSvsmPresent()

BOOLEAN EFIAPI AmdSvsmIsSvsmPresent ( VOID  )

Report the presence of an Secure Virtual Services Module (SVSM).

Determines the presence of an SVSM.

Return values
TRUEAn SVSM is present
FALSEAn SVSM is not present

Definition at line 24 of file AmdSvsmLibNull.c.

◆ AmdSvsmSnpGetCaa()

UINT64 EFIAPI AmdSvsmSnpGetCaa ( VOID  )

Report the Calling Area address (CAA) for the BSP of the SEV-SNP guest.

If an SVSM is present, the CAA for the BSP is returned.

Returns
The CAA

Definition at line 60 of file AmdSvsmLibNull.c.

◆ AmdSvsmSnpGetVmpl()

UINT8 EFIAPI AmdSvsmSnpGetVmpl ( VOID  )

Report the VMPL level at which the SEV-SNP guest is running.

Determines the VMPL level at which the guest is running. If an SVSM is not present, then it must be VMPL0, otherwise return what is reported by the SVSM.

Returns
The VMPL level

Definition at line 43 of file AmdSvsmLibNull.c.

◆ AmdSvsmSnpPvalidate()

VOID EFIAPI AmdSvsmSnpPvalidate ( IN SNP_PAGE_STATE_CHANGE_INFO Info)

Perform a PVALIDATE operation for the page ranges specified.

Validate or rescind the validation of the specified pages.

Parameters
[in]InfoPointer to a page state change structure

Definition at line 77 of file AmdSvsmLibNull.c.

◆ AmdSvsmSnpVmsaRmpAdjust()

EFI_STATUS EFIAPI AmdSvsmSnpVmsaRmpAdjust ( IN SEV_ES_SAVE_AREA Vmsa,
IN UINT32  ApicId,
IN BOOLEAN  SetVmsa 
)

Perform an RMPADJUST operation to alter the VMSA setting of a page.

Add or remove the VMSA attribute for a page.

Parameters
[in]VmsaPointer to an SEV-ES save area page
[in]ApicIdAPIC ID associated with the VMSA
[in]SetVmsaBoolean indicator as to whether to set or or clear the VMSA setting for the page
Return values
EFI_SUCCESSRMPADJUST operation successful
EFI_UNSUPPORTEDOperation is not supported
EFI_INVALID_PARAMETERRMPADJUST operation failed, an invalid parameter was supplied

Definition at line 101 of file AmdSvsmLibNull.c.