mirror of
https://github.com/brain-hackers/u-boot-brain
synced 2024-09-28 23:50:26 +09:00
efi_loader: return status from efi_setup_loaded_image()
efi_setup_loaded_image() should return an error code indicating if an error has occurred. An error occurs if a protocol cannot be installed. Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Signed-off-by: Alexander Graf <agraf@suse.de>
This commit is contained in:
parent
905cb9e172
commit
56d9288858
@ -249,7 +249,9 @@ uint64_t efi_add_memory_map(uint64_t start, uint64_t pages, int memory_type,
|
||||
int efi_memory_init(void);
|
||||
/* Adds new or overrides configuration table entry to the system table */
|
||||
efi_status_t efi_install_configuration_table(const efi_guid_t *guid, void *table);
|
||||
void efi_setup_loaded_image(struct efi_loaded_image *info, struct efi_object *obj,
|
||||
/* Sets up a loaded image */
|
||||
efi_status_t efi_setup_loaded_image(
|
||||
struct efi_loaded_image *info, struct efi_object *obj,
|
||||
struct efi_device_path *device_path,
|
||||
struct efi_device_path *file_path);
|
||||
efi_status_t efi_load_image_from_path(struct efi_device_path *file_path,
|
||||
|
@ -1170,8 +1170,10 @@ static efi_status_t EFIAPI efi_install_configuration_table_ext(efi_guid_t *guid,
|
||||
* @obj internal object associated with the loaded image
|
||||
* @device_path device path of the loaded image
|
||||
* @file_path file path of the loaded image
|
||||
* @return status code
|
||||
*/
|
||||
void efi_setup_loaded_image(struct efi_loaded_image *info, struct efi_object *obj,
|
||||
efi_status_t efi_setup_loaded_image(
|
||||
struct efi_loaded_image *info, struct efi_object *obj,
|
||||
struct efi_device_path *device_path,
|
||||
struct efi_device_path *file_path)
|
||||
{
|
||||
@ -1213,9 +1215,10 @@ void efi_setup_loaded_image(struct efi_loaded_image *info, struct efi_object *ob
|
||||
if (ret != EFI_SUCCESS)
|
||||
goto failure;
|
||||
|
||||
return;
|
||||
return ret;
|
||||
failure:
|
||||
printf("ERROR: Failure to install protocols for loaded image\n");
|
||||
return ret;
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user