diff options
| author | Michael Brown | 2013-03-20 16:25:16 +0100 |
|---|---|---|
| committer | Michael Brown | 2013-03-20 16:25:16 +0100 |
| commit | 1920aa43764981597da57616cdb75c040d730712 (patch) | |
| tree | 51e112a4bd77c304a6cbd5747d1a814ebd6cbb52 /src/include/ipxe/efi | |
| parent | [uuid] Abstract UUID mangling code out to a separate uuid_mangle() function (diff) | |
| download | ipxe-1920aa43764981597da57616cdb75c040d730712.tar.gz ipxe-1920aa43764981597da57616cdb75c040d730712.tar.xz ipxe-1920aa43764981597da57616cdb75c040d730712.zip | |
[efi] Provide efi_guid_ntoa() for printing EFI GUIDs
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include/ipxe/efi')
| -rw-r--r-- | src/include/ipxe/efi/efi.h | 19 |
1 files changed, 5 insertions, 14 deletions
diff --git a/src/include/ipxe/efi/efi.h b/src/include/ipxe/efi/efi.h index 880872aac..46b66690d 100644 --- a/src/include/ipxe/efi/efi.h +++ b/src/include/ipxe/efi/efi.h @@ -54,12 +54,7 @@ /** An EFI protocol used by iPXE */ struct efi_protocol { /** GUID */ - union { - /** EFI protocol GUID */ - EFI_GUID guid; - /** UUID structure understood by iPXE */ - union uuid uuid; - } u; + EFI_GUID guid; /** Variable containing pointer to protocol structure */ void **protocol; }; @@ -77,7 +72,7 @@ struct efi_protocol { */ #define EFI_REQUIRE_PROTOCOL( _protocol, _ptr ) \ struct efi_protocol __ ## _protocol __efi_protocol = { \ - .u.guid = _protocol ## _GUID, \ + .guid = _protocol ## _GUID, \ .protocol = ( ( void ** ) ( void * ) \ ( ( (_ptr) == ( ( _protocol ** ) (_ptr) ) ) ? \ (_ptr) : (_ptr) ) ), \ @@ -86,12 +81,7 @@ struct efi_protocol { /** An EFI configuration table used by iPXE */ struct efi_config_table { /** GUID */ - union { - /** EFI configuration table GUID */ - EFI_GUID guid; - /** UUID structure understood by iPXE */ - union uuid uuid; - } u; + EFI_GUID guid; /** Variable containing pointer to configuration table */ void **table; /** Table is required for operation */ @@ -113,7 +103,7 @@ struct efi_config_table { */ #define EFI_USE_TABLE( _table, _ptr, _required ) \ struct efi_config_table __ ## _table __efi_config_table = { \ - .u.guid = _table ## _GUID, \ + .guid = _table ## _GUID, \ .table = ( ( void ** ) ( void * ) (_ptr) ), \ .required = (_required), \ } @@ -140,6 +130,7 @@ extern EFI_LOADED_IMAGE_PROTOCOL *efi_loaded_image; extern EFI_SYSTEM_TABLE *efi_systab; extern const char * efi_strerror ( EFI_STATUS efirc ); +extern const char * efi_guid_ntoa ( EFI_GUID *guid ); extern void dbg_efi_protocols ( EFI_HANDLE handle ); extern void dbg_efi_devpath ( EFI_DEVICE_PATH_PROTOCOL *path ); |
