diff options
| author | Simon Glass <[email protected]> | 2019-09-25 08:11:32 -0600 |
|---|---|---|
| committer | Bin Meng <[email protected]> | 2019-10-08 13:54:12 +0800 |
| commit | fdeb6f7dc6ed81ba50f1b56eb4bade9108f5f145 (patch) | |
| tree | 39b31f556f7e997d43925337a8cdad11f0c962ac /include/efi_loader.h | |
| parent | 62888d840fb99d0375dc33ef7b3404377f451bcf (diff) | |
efi: Move inline functions to unconditional part of header
At present these two functions are defined in efi_loader.h but only if
CONFIG_EFI_LOADER is enabled. But these are functions that are useful to
other code, such as that which deals with Intel Handoff Blocks (HOBs).
Move these to the top of the function.
Possibly ascii2unicode() should not be an inline function, since this
might impact code size.
Signed-off-by: Simon Glass <[email protected]>
Reviewed-by: Bin Meng <[email protected]>
Diffstat (limited to 'include/efi_loader.h')
| -rw-r--r-- | include/efi_loader.h | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/include/efi_loader.h b/include/efi_loader.h index 53b369945b4..381da80cdce 100644 --- a/include/efi_loader.h +++ b/include/efi_loader.h @@ -12,6 +12,11 @@ #include <part_efi.h> #include <efi_api.h> +static inline int guidcmp(const void *g1, const void *g2) +{ + return memcmp(g1, g2, sizeof(efi_guid_t)); +} + /* No need for efi loader support in SPL */ #if CONFIG_IS_ENABLED(EFI_LOADER) @@ -563,11 +568,6 @@ efi_status_t efi_dp_from_name(const char *dev, const char *devnr, (((_dp)->type == DEVICE_PATH_TYPE_##_type) && \ ((_dp)->sub_type == DEVICE_PATH_SUB_TYPE_##_subtype)) -static inline int guidcmp(const void *g1, const void *g2) -{ - return memcmp(g1, g2, sizeof(efi_guid_t)); -} - /* * Use these to indicate that your code / data should go into the EFI runtime * section and thus still be available when the OS is running |
