70 size_t wname_len = ( (
wcslen ( wname ) + 1 ) *
sizeof ( wname[0] ) );
78 size =
sizeof ( buf[0] );
103 DBGC ( &
efivars,
"EFIVARS %s:%ls could not fetch next "
104 "variable name: %s\n",
112 if (
memcmp ( wname, buf, wname_len ) == 0 ) {
137 CHAR16 wname[ name_len + 1 ];
157 DBGC ( &
efivars,
"EFIVARS %s:%ls could not get size: %s\n",
176 DBGC ( &
efivars,
"EFIVARS %s:%ls could not get %zd bytes: "
228 DBGC ( &
efivars,
"EFIVARS could not register: %s\n",
UINT64 UINTN
Unsigned value of native width.
unsigned short CHAR16
2-byte Character.
unsigned int UINT32
4-byte unsigned value.
#define NULL
NULL pointer (VOID *)
#define EFI_NOT_FOUND
Enumeration of EFI_STATUS.
RETURN_STATUS EFI_STATUS
Function return status for EFI API.
GUID EFI_GUID
128-bit buffer containing a unique identifier value.
#define EFI_BUFFER_TOO_SMALL
Enumeration of EFI_STATUS.
struct arbelprm_rc_send_wqe rc
const char * efi_guid_ntoa(CONST EFI_GUID *guid)
Convert GUID to a printable string.
static int efivars_fetch(struct settings *settings __unused, struct setting *setting, void *data, size_t len)
Fetch value of EFI variable setting.
static const struct settings_scope efivars_scope
EFI variable settings scope.
static void efivars_init(void)
Initialise EFI variable settings.
static struct settings efivars
EFI variable settings.
static int efivars_find(const CHAR16 *wname, EFI_GUID *guid)
Find first matching EFI variable name.
static int efivars_applies(struct settings *settings __unused, const struct setting *setting)
Check applicability of EFI variable setting.
static struct settings_operations efivars_operations
EFI variable settings operations.
int efi_snprintf(wchar_t *wbuf, size_t wsize, const char *fmt,...)
Write a formatted string to a buffer.
uint8_t data[48]
Additional event data.
#define __unused
Declare a variable or data structure as unused.
#define INIT_NORMAL
Normal initialisation.
uint16_t size
Buffer size.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
#define ENOENT
No such file or directory.
#define ENOMEM
Not enough space.
#define FILE_SECBOOT(_status)
Declare a file's UEFI Secure Boot permission status.
#define EEFI(efirc)
Convert an EFI status code to an iPXE status code.
EFI_SYSTEM_TABLE * efi_systab
void * memcpy(void *dest, const void *src, size_t len) __nonnull
#define __init_fn(init_order)
Declare an initialisation functon.
#define LIST_HEAD_INIT(list)
Initialise a static list head.
void * realloc(void *old_ptr, size_t new_size)
Reallocate memory.
void * zalloc(size_t size)
Allocate cleared memory.
void * malloc(size_t size)
Allocate memory.
static void(* free)(struct refcnt *refcnt))
int register_settings(struct settings *settings, struct settings *parent, const char *name)
Register settings block.
char * strerror(int errno)
Retrieve string representation of error number.
int memcmp(const void *first, const void *second, size_t len)
Compare memory regions.
size_t strlen(const char *src)
Get length of string.
EFI Runtime Services Table.
EFI_GET_NEXT_VARIABLE_NAME GetNextVariableName
EFI_GET_VARIABLE GetVariable
An initialisation function.
const struct settings_scope * scope
Setting scope (or NULL)
const struct setting_type * type
Setting type.
Settings block operations.
size_t wcslen(const wchar_t *string)
Calculate length of wide-character string.