From patchwork Tue Aug 9 08:09:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 596551 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 63E4EC3F6B0 for ; Tue, 9 Aug 2022 08:10:52 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238680AbiHIIKv (ORCPT ); Tue, 9 Aug 2022 04:10:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54364 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233351AbiHIIKu (ORCPT ); Tue, 9 Aug 2022 04:10:50 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A2BA6B7D1 for ; Tue, 9 Aug 2022 01:10:49 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 39211612EC for ; Tue, 9 Aug 2022 08:10:49 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id B4A61C43470; Tue, 9 Aug 2022 08:10:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1660032648; bh=oPI34RZJsbqu67SVjCqjTm3yri4pEDmQ8oGlXGswDt4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=c2BgEpnEHRCBU6deIy1tTjY3gDOtzcuHGehaArf0vSVWkk0KVOFB8zVsdHz3HHwdp cCtNY8XfQ+ZuCydfs/xq9meoa06ODEbJHb0W8cqf40Go2Ky0W3aIe5Ir76DpQDOqqw VImjEXS7dRLl5ptHZSRmEOvGorJ8e3HQo8nqK8KkdB/LQ+YMLieQ+YJcZyd+KbV5O3 eH33Ny+Ua7jdM41RgzNNhv8S0z3h22eKVdpfsnAeNV6Din2RISEfBEhet6cuNj883V HguWcbcZ01QJaZndHAm3I7JL6HOnEwcSYRobj4Mz6HOZMyAxy/8T+BC0jyjkQn1CpZ LwdQ8nSDltqZQ== From: Ard Biesheuvel To: linux-efi@vger.kernel.org Cc: catalin.marinas@arm.com, will@kernel.org, Ard Biesheuvel , "James E.J. Bottomley" , Matthew Garrett , Peter Jones , Ilias Apalodimas , Heinrich Schuchardt , AKASHI Takahiro , Palmer Dabbelt , Atish Patra , Arnd Bergmann , Huacai Chen , Lennart Poettering Subject: [PATCH v2 1/6] efi: stub: add some missing boot service prototypes Date: Tue, 9 Aug 2022 10:09:39 +0200 Message-Id: <20220809080944.1119654-2-ardb@kernel.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220809080944.1119654-1-ardb@kernel.org> References: <20220809080944.1119654-1-ardb@kernel.org> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1680; i=ardb@kernel.org; h=from:subject; bh=oPI34RZJsbqu67SVjCqjTm3yri4pEDmQ8oGlXGswDt4=; b=owEB7QES/pANAwAKAcNPIjmS2Y8kAcsmYgBi8hY7ATzyeS13+RsJEB0BDPtDvOIVLLRn/Pnv5naG 1XmCPxCJAbMEAAEKAB0WIQT72WJ8QGnJQhU3VynDTyI5ktmPJAUCYvIWOwAKCRDDTyI5ktmPJLgFDA CbwpnyvgWvP2EVFScqm776+NayZniECezqggB0s1jyWwAhQDx9rODPCeYuJKSXizzQxHM/dVB80/24 DJsjWABXdwy1Kbj5qE7GYpnOT6Xiwuysr8bJolDEuSffE2lOZGFTajxJqjeWBEhieUH9vZQqO2Kta7 YaVtpzwJ70OKdSZ3hFubVVkRWSv1bUN8g8RyZFv4+uAHkYKMU7mx6r35lEYkSbRA0KmULbYSVbHHmC blddw2R6ufT00XGwNbcDQCNwIi5sMWGEKTBn/dOVDDIak029mDtKSUOYy5Ha5IW/FyNeLbsTUVkucn AVpMRdrgUBDM24gUKBskm42zKBHX20HZBI4UNRvXX1bhGl7NM7sJbKvj9XhXH99pJSpdClsGo1VBUP KFalSIwFRn+LOOWtOaEPFCqDz5OOxcPC3UExQPlGb9HDcRRV6xadKVWa87bhU/dPqUX0LbbJosYkyI rIL+yZAQBfmcGuHFnaiwURxpGrPkyIZV+4QbUfFgUogz0= X-Developer-Key: i=ardb@kernel.org; a=openpgp; fpr=F43D03328115A198C90016883D200E9CA6329909 Precedence: bulk List-ID: X-Mailing-List: linux-efi@vger.kernel.org Define the correct prototypes for the load_image/start_image and install_multiple_protocol_interfaces boot service pointers so we can call them from the EFI zboot code. Signed-off-by: Ard Biesheuvel --- drivers/firmware/efi/libstub/efistub.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/drivers/firmware/efi/libstub/efistub.h b/drivers/firmware/efi/libstub/efistub.h index ab9e990447d3..33215d7bd276 100644 --- a/drivers/firmware/efi/libstub/efistub.h +++ b/drivers/firmware/efi/libstub/efistub.h @@ -254,8 +254,12 @@ union efi_boot_services { efi_handle_t *); efi_status_t (__efiapi *install_configuration_table)(efi_guid_t *, void *); - void *load_image; - void *start_image; + efi_status_t (__efiapi *load_image)(bool, efi_handle_t, + efi_device_path_protocol_t *, + void *, unsigned long, + efi_handle_t *); + efi_status_t (__efiapi *start_image)(efi_handle_t, unsigned long *, + efi_char16_t **); efi_status_t __noreturn (__efiapi *exit)(efi_handle_t, efi_status_t, unsigned long, @@ -277,8 +281,8 @@ union efi_boot_services { void *locate_handle_buffer; efi_status_t (__efiapi *locate_protocol)(efi_guid_t *, void *, void **); - void *install_multiple_protocol_interfaces; - void *uninstall_multiple_protocol_interfaces; + efi_status_t (__efiapi *install_multiple_protocol_interfaces)(efi_handle_t *, ...); + efi_status_t (__efiapi *uninstall_multiple_protocol_interfaces)(efi_handle_t, ...); void *calculate_crc32; void *copy_mem; void *set_mem;