From patchwork Fri Jan 10 21:17:14 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Heinrich Schuchardt X-Patchwork-Id: 239444 List-Id: U-Boot discussion From: xypron.glpk at gmx.de (Heinrich Schuchardt) Date: Fri, 10 Jan 2020 22:17:14 +0100 Subject: [PATCH 1/1] efi_loader: describe returning of control Message-ID: <20200110211714.30575-1-xypron.glpk@gmx.de> Provide a sober description of how control can be returned by a UEFI binary. Signed-off-by: Heinrich Schuchardt --- lib/efi_loader/efi_boottime.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) -- 2.24.1 diff --git a/lib/efi_loader/efi_boottime.c b/lib/efi_loader/efi_boottime.c index fad2bdc400..80daa21347 100644 --- a/lib/efi_loader/efi_boottime.c +++ b/lib/efi_loader/efi_boottime.c @@ -2933,10 +2933,10 @@ efi_status_t EFIAPI efi_start_image(efi_handle_t image_handle, ret = EFI_CALL(image_obj->entry(image_handle, &systab)); /* - * Usually UEFI applications call Exit() instead of returning. - * But because the world doesn't consist of ponies and unicorns, - * we're happy to emulate that behavior on behalf of a payload - * that forgot. + * Control is returned from a started UEFI image either by calling + * Exit() (where exit data can be provided) or by simply returning from + * the entry point. In the latter case call Exit() on behalf of the + * image. */ return EFI_CALL(systab.boottime->exit(image_handle, ret, 0, NULL)); }