From 58cf755d5fd5b3d1f87a5936107a70705ccbb57b Mon Sep 17 00:00:00 2001 From: Peter Jones Date: Thu, 25 Feb 2021 23:18:24 -0500 Subject: Add get_variable_size()/set_variable()del_variable() wrappers. This get_variable_size() implementation success in either of two cases: - EFI_SUCCESS with *lenp == 0 if the variable isn't found - EFI_SUCCESS with *lenp > 0 on success In the event of other errors, it returns them to you. There's nothing particularly interesting about the set_variable() or del_variable() implementation here. Signed-off-by: Peter Jones --- include/variables.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include/variables.h') diff --git a/include/variables.h b/include/variables.h index 09d97c31..31cfcb65 100644 --- a/include/variables.h +++ b/include/variables.h @@ -40,6 +40,12 @@ get_variable(const CHAR16 * const var, UINT8 **data, UINTN *len, EFI_GUID owner) EFI_STATUS get_variable_attr(const CHAR16 * const var, UINT8 **data, UINTN *len, EFI_GUID owner, UINT32 *attributes); EFI_STATUS +get_variable_size(const CHAR16 * const var, EFI_GUID owner, UINTN *lenp); +EFI_STATUS +set_variable(CHAR16 *var, EFI_GUID owner, UINT32 attributes, UINTN datasize, void *data); +EFI_STATUS +del_variable(CHAR16 *var, EFI_GUID owner); +EFI_STATUS find_in_esl(UINT8 *Data, UINTN DataSize, UINT8 *key, UINTN keylen); EFI_STATUS find_in_variable_esl(const CHAR16 * const var, EFI_GUID owner, UINT8 *key, UINTN keylen); -- cgit v1.2.3