]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
efi_loader: add definition for efi_main()
authorHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Fri, 10 Feb 2023 07:23:24 +0000 (08:23 +0100)
committerHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Fri, 10 Feb 2023 12:05:40 +0000 (13:05 +0100)
U-Boot provides multiple EFI applications. The entry point is called
efi_main(). Provide a definition for this function. This avoids
build warnings like

    lib/efi_loader/initrddump.c:468:21: warning:
    no previous prototype for ‘efi_main’ [-Wmissing-prototypes]
      468 | efi_status_t EFIAPI efi_main(efi_handle_t image_handle,
          |                     ^~~~~~~~

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
include/efi_api.h

index e1cdaf52479696ec8324ab4c39904b1ec357d92b..2d18d25a7137bcc400c6e559a207cf285dfa4b06 100644 (file)
@@ -513,6 +513,16 @@ struct efi_system_table {
        struct efi_configuration_table *tables;
 };
 
+/**
+ * efi_main() - entry point of EFI applications
+ *
+ * @image_handle:      handle with the Loaded Image Protocol
+ * @systab:            pointer to the system table
+ * Return:             status code
+ */
+efi_status_t EFIAPI efi_main(efi_handle_t image_handle,
+                            struct efi_system_table *systab);
+
 #define EFI_LOADED_IMAGE_PROTOCOL_GUID \
        EFI_GUID(0x5b1b31a1, 0x9562, 0x11d2, \
                 0x8e, 0x3f, 0x00, 0xa0, 0xc9, 0x69, 0x72, 0x3b)