]>
git.proxmox.com Git - mirror_edk2.git/blob - SecurityPkg/Tcg/MemoryOverwriteRequestControlLock/TcgMorLock.h
2 TCG MOR (Memory Overwrite Request) Lock Control Driver header file.
4 Copyright (c) 2015 - 2018, Intel Corporation. All rights reserved.<BR>
5 SPDX-License-Identifier: BSD-2-Clause-Patent
9 #ifndef _EFI_TCG_MOR_LOCK_H_
10 #define _EFI_TCG_MOR_LOCK_H_
13 This service is a wrapper for the UEFI Runtime Service GetVariable().
15 @param VariableName the name of the vendor's variable, it's a Null-Terminated Unicode String
16 @param VendorGuid Unify identifier for vendor.
17 @param Attributes Point to memory location to return the attributes of variable. If the point
18 is NULL, the parameter would be ignored.
19 @param DataSize As input, point to the maximum size of return Data-Buffer.
20 As output, point to the actual size of the returned Data-Buffer.
21 @param Data Point to return Data-Buffer.
23 @retval EFI_SUCCESS The function completed successfully.
24 @retval EFI_NOT_FOUND The variable was not found.
25 @retval EFI_BUFFER_TOO_SMALL The DataSize is too small for the result. DataSize has
26 been updated with the size needed to complete the request.
27 @retval EFI_INVALID_PARAMETER VariableName is NULL.
28 @retval EFI_INVALID_PARAMETER VendorGuid is NULL.
29 @retval EFI_INVALID_PARAMETER DataSize is NULL.
30 @retval EFI_INVALID_PARAMETER The DataSize is not too small and Data is NULL.
31 @retval EFI_DEVICE_ERROR The variable could not be retrieved due to a hardware error.
32 @retval EFI_SECURITY_VIOLATION The variable could not be retrieved due to an authentication failure.
37 IN CHAR16
*VariableName
,
38 IN EFI_GUID
*VendorGuid
,
39 OUT UINT32
*Attributes OPTIONAL
,
40 IN OUT UINTN
*DataSize
,
45 This service is a wrapper for the UEFI Runtime Service SetVariable()
47 @param VariableName the name of the vendor's variable, as a
48 Null-Terminated Unicode String
49 @param VendorGuid Unify identifier for vendor.
50 @param Attributes Point to memory location to return the attributes of variable. If the point
51 is NULL, the parameter would be ignored.
52 @param DataSize The size in bytes of Data-Buffer.
53 @param Data Point to the content of the variable.
55 @retval EFI_SUCCESS The firmware has successfully stored the variable and its data as
56 defined by the Attributes.
57 @retval EFI_INVALID_PARAMETER An invalid combination of attribute bits was supplied, or the
58 DataSize exceeds the maximum allowed.
59 @retval EFI_INVALID_PARAMETER VariableName is an empty Unicode string.
60 @retval EFI_OUT_OF_RESOURCES Not enough storage is available to hold the variable and its data.
61 @retval EFI_DEVICE_ERROR The variable could not be saved due to a hardware failure.
62 @retval EFI_WRITE_PROTECTED The variable in question is read-only.
63 @retval EFI_WRITE_PROTECTED The variable in question cannot be deleted.
64 @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS
65 set but the AuthInfo does NOT pass the validation check carried
67 @retval EFI_NOT_FOUND The variable trying to be updated or deleted was not found.
73 IN CHAR16
*VariableName
,
74 IN EFI_GUID
*VendorGuid
,
81 This service is a checker handler for the UEFI Runtime Service SetVariable()
83 @param VariableName the name of the vendor's variable, as a
84 Null-Terminated Unicode String
85 @param VendorGuid Unify identifier for vendor.
86 @param Attributes Point to memory location to return the attributes of variable. If the point
87 is NULL, the parameter would be ignored.
88 @param DataSize The size in bytes of Data-Buffer.
89 @param Data Point to the content of the variable.
91 @retval EFI_SUCCESS The firmware has successfully stored the variable and its data as
92 defined by the Attributes.
93 @retval EFI_INVALID_PARAMETER An invalid combination of attribute bits was supplied, or the
94 DataSize exceeds the maximum allowed.
95 @retval EFI_INVALID_PARAMETER VariableName is an empty Unicode string.
96 @retval EFI_OUT_OF_RESOURCES Not enough storage is available to hold the variable and its data.
97 @retval EFI_DEVICE_ERROR The variable could not be saved due to a hardware failure.
98 @retval EFI_WRITE_PROTECTED The variable in question is read-only.
99 @retval EFI_WRITE_PROTECTED The variable in question cannot be deleted.
100 @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS
101 set but the AuthInfo does NOT pass the validation check carried
103 @retval EFI_NOT_FOUND The variable trying to be updated or deleted was not found.
108 SetVariableCheckHandlerMor (
109 IN CHAR16
*VariableName
,
110 IN EFI_GUID
*VendorGuid
,
111 IN UINT32 Attributes
,
117 Entry Point for MOR Lock Control driver.
119 @param[in] ImageHandle Image handle of this driver.
120 @param[in] SystemTable A Pointer to the EFI System Table.
123 @return Others Some error occurs.