]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
efi_loader: address coverity report 492766 for dead code
authorIlias Apalodimas <ilias.apalodimas@linaro.org>
Tue, 23 Apr 2024 05:38:06 +0000 (08:38 +0300)
committerHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Wed, 1 May 2024 05:39:27 +0000 (07:39 +0200)
The check of the return code is already done a few lines above.
Although it doesn't cause any functional issues, remove the superfluous
checks

Addresses-Coverity-ID: 492766 Control flow issues  (DEADCODE)
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
lib/efi_loader/efi_var_mem.c

index 940ab663882396b91531aabac24745333eaa5632..139e16aad7c6e68696d9b4df002fa5c016c7fb6e 100644 (file)
@@ -232,8 +232,6 @@ efi_status_t efi_var_mem_init(void)
        efi_var_buf->length = (uintptr_t)efi_var_buf->var -
                              (uintptr_t)efi_var_buf;
 
-       if (ret != EFI_SUCCESS)
-               return ret;
        ret = efi_create_event(EVT_SIGNAL_VIRTUAL_ADDRESS_CHANGE, TPL_CALLBACK,
                               efi_var_mem_notify_virtual_address_map, NULL,
                               NULL, &event);