summaryrefslogtreecommitdiff
path: root/include/efi_loader.h
diff options
context:
space:
mode:
authorHeinrich Schuchardt <xypron.glpk@gmx.de>2018-01-19 20:24:37 +0100
committerAlexander Graf <agraf@suse.de>2018-01-22 23:09:13 +0100
commit04298686a43af15c091393fac71fc42e73efddbd (patch)
tree6ac13a8ba758413738cf7af23962694b20806963 /include/efi_loader.h
parent2074f70064b5860db0d273ad3d050e87764c08e5 (diff)
efi_loader: return NULL from device path functions
For the construction of device paths we need to call the AllocatePool service. We should not ignore if it fails due to an out of memory situation. This patch changes the device path functions to return NULL if the memory allocation fails. Additional patches will be needed to fix the callers. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'include/efi_loader.h')
-rw-r--r--include/efi_loader.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/efi_loader.h b/include/efi_loader.h
index 37389c33cc..6b623d8327 100644
--- a/include/efi_loader.h
+++ b/include/efi_loader.h
@@ -304,9 +304,9 @@ struct efi_device_path *efi_dp_from_eth(void);
struct efi_device_path *efi_dp_from_mem(uint32_t mem_type,
uint64_t start_address,
uint64_t end_address);
-void efi_dp_split_file_path(struct efi_device_path *full_path,
- struct efi_device_path **device_path,
- struct efi_device_path **file_path);
+efi_status_t efi_dp_split_file_path(struct efi_device_path *full_path,
+ struct efi_device_path **device_path,
+ struct efi_device_path **file_path);
#define EFI_DP_TYPE(_dp, _type, _subtype) \
(((_dp)->type == DEVICE_PATH_TYPE_##_type) && \