From mboxrd@z Thu Jan 1 00:00:00 1970 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 DA9F0ECAAD5 for ; Sat, 10 Sep 2022 08:13:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229796AbiIJIM6 (ORCPT ); Sat, 10 Sep 2022 04:12:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34536 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229688AbiIJIMj (ORCPT ); Sat, 10 Sep 2022 04:12:39 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7B3E4868AC; Sat, 10 Sep 2022 01:12:36 -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 D592C60C01; Sat, 10 Sep 2022 08:12:34 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9C67DC4347C; Sat, 10 Sep 2022 08:12:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1662797554; bh=GuY8276n/eRax8D4bN0N+JvUa77cwpfHICfgt9doQ1c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=stQqAy1gyraU9bRDfAFnVamiw1VRMdBu7IPx1EvA2EDnWH61QnCkVGJ8NLhEA89G+ F9Rr5CJygeXjkOpesQ2vptfRolRDOcuFAPe6fqVqH1DDio0rpXZE9zkE4PMBGNp5gJ 2SL2ghVUEA2OH8MMOzkjPxmjcQ64xmioza/6Ft9SkKAR01bPfykYvNDup6L439jDMA lX1DDRYsRCd7Ow58H9qqf/559otFyk9xjh/v/kHbdprLgAE8vUJSbpfMDLHuc+vprv bnhWGdzgE/muly+j9rIhvLcSM9MnYnSGW2wGWIrBgfzhKz4Zu7KhHlpgTrkC5BQ0sw 9Wf7zXkf5KQ1g== From: Ard Biesheuvel To: linux-efi@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.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 , Xi Ruoyao , Lennart Poettering , Jeremy Linton , Will Deacon , Catalin Marinas Subject: [PATCH v5 6/8] arm64: efi: enable generic EFI compressed boot Date: Sat, 10 Sep 2022 10:11:50 +0200 Message-Id: <20220910081152.2238369-7-ardb@kernel.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220910081152.2238369-1-ardb@kernel.org> References: <20220910081152.2238369-1-ardb@kernel.org> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1642; i=ardb@kernel.org; h=from:subject; bh=GuY8276n/eRax8D4bN0N+JvUa77cwpfHICfgt9doQ1c=; b=owEB7QES/pANAwAKAcNPIjmS2Y8kAcsmYgBjHEbF8hJQ56ln/A/CC0taX3RBGiOeGIn/epSviNNT QJsSLjyJAbMEAAEKAB0WIQT72WJ8QGnJQhU3VynDTyI5ktmPJAUCYxxGxQAKCRDDTyI5ktmPJL8EDA CTUabsOcQV2xcWs4ccVK9JFyN0ArpMIc1LF7Ms9VYhLgxfPjQeZKNqdd2P7EU/Bvap6NsAwP85miC+ T5oXg9W6gGNd5hZ4bun9/72wXu1F1x+icitwh0nyFzeUcCUsaWpESFV9JWjgCKbewl3XIcmgDMqrlU O9GDST5OloaKjDFI2dhu1QeJYlqfclvyms/+AE9DOMvVWVEstMaTLvht0ols+p/82V0pdWxOB+oC7b zRfp+EZanT+oqL7CCIzqWQVPf3KIJaVhKTTd8PXduutM9t4C7+0o1W8RqLUrFHCVcLTJqGSP341sng 0Vd016ChIJqsNQxZUOBEPWODEyXmghiLCKNq3LHRXKoAy4tRg757PBPUzTtGtJ0B9wnnVDC1S2/pq8 Yqgqdul0Ge0ZCJgaRU9Su4iHwbbZObmaCGFh/t/BEhG9CKaK/s0J+cJNh3KBoD5MeLyovsbbh+KjKz lem/Xo2Av03S1nfBB+YA+AU2Gu/FIIrDR3AqsI2EdnH7k= X-Developer-Key: i=ardb@kernel.org; a=openpgp; fpr=F43D03328115A198C90016883D200E9CA6329909 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Wire up the generic EFI zboot support for arm64. Signed-off-by: Ard Biesheuvel --- arch/arm64/Makefile | 9 +++++++-- arch/arm64/boot/.gitignore | 1 + arch/arm64/boot/Makefile | 6 ++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index 6d9d4a58b898..a82bb3599094 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -151,12 +151,17 @@ libs-$(CONFIG_EFI_STUB) += $(objtree)/drivers/firmware/efi/libstub/lib.a # Default target when executing plain make boot := arch/arm64/boot + +ifeq ($(CONFIG_EFI_ZBOOT),) KBUILD_IMAGE := $(boot)/Image.gz +else +KBUILD_IMAGE := $(boot)/vmlinuz.efi +endif -all: Image.gz +all: $(notdir $(KBUILD_IMAGE)) -Image: vmlinux +Image vmlinuz.efi: vmlinux $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ Image.%: Image diff --git a/arch/arm64/boot/.gitignore b/arch/arm64/boot/.gitignore index 9a7a9009d43a..af5dc61f8b43 100644 --- a/arch/arm64/boot/.gitignore +++ b/arch/arm64/boot/.gitignore @@ -1,3 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only Image Image.gz +vmlinuz* diff --git a/arch/arm64/boot/Makefile b/arch/arm64/boot/Makefile index a0e3dedd2883..c65aee088410 100644 --- a/arch/arm64/boot/Makefile +++ b/arch/arm64/boot/Makefile @@ -38,3 +38,9 @@ $(obj)/Image.lzo: $(obj)/Image FORCE $(obj)/Image.zst: $(obj)/Image FORCE $(call if_changed,zstd) + +EFI_ZBOOT_PAYLOAD := Image +EFI_ZBOOT_BFD_TARGET := elf64-littleaarch64 +EFI_ZBOOT_MACH_TYPE := ARM64 + +include $(srctree)/drivers/firmware/efi/libstub/Makefile.zboot -- 2.35.1 From mboxrd@z Thu Jan 1 00:00:00 1970 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 77798C6FA82 for ; Sat, 10 Sep 2022 08:14:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=/IzLxKSYWby1Y95ZGIM1NSNJEWGD5bsAzzWH2hb43J4=; b=pa29A2n1phEmsj tQcMcDo3dhf2f8XhbGaMsPnAoJWdXob2FACffvNQGhS6SO/4XD6psXX2TUV9oVs+yGUyHTgAjCt6z 8xK5sP2XV8ZQ7SSJIDH0u5jN8Xb0rC9XoXMfR/OMJj5HR0jIoEqSkVT3zDtPFE8a5I4U7mOjiDBp8 Xe5CfAlX17feYfxrYrHxsHpYlPA+xIWZBey9jDcOv/Gb9h9Wf52xUzOch9nRrGfd7+vKR0yKIx0c5 8kuGqtdQCgfRtvRHRgM4ZWBapyjlxjhbL1yoewXib0YrUyc15C2j0yiscRe1R+BQJXPQXmTyUrbw2 JUFEQ3YLenzewqSiyUrg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWvcF-008c5v-Ri; Sat, 10 Sep 2022 08:13:28 +0000 Received: from dfw.source.kernel.org ([139.178.84.217]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1oWvbP-008biu-RK for linux-arm-kernel@lists.infradead.org; Sat, 10 Sep 2022 08:12:37 +0000 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 7113D61137; Sat, 10 Sep 2022 08:12:35 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9C67DC4347C; Sat, 10 Sep 2022 08:12:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1662797554; bh=GuY8276n/eRax8D4bN0N+JvUa77cwpfHICfgt9doQ1c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=stQqAy1gyraU9bRDfAFnVamiw1VRMdBu7IPx1EvA2EDnWH61QnCkVGJ8NLhEA89G+ F9Rr5CJygeXjkOpesQ2vptfRolRDOcuFAPe6fqVqH1DDio0rpXZE9zkE4PMBGNp5gJ 2SL2ghVUEA2OH8MMOzkjPxmjcQ64xmioza/6Ft9SkKAR01bPfykYvNDup6L439jDMA lX1DDRYsRCd7Ow58H9qqf/559otFyk9xjh/v/kHbdprLgAE8vUJSbpfMDLHuc+vprv bnhWGdzgE/muly+j9rIhvLcSM9MnYnSGW2wGWIrBgfzhKz4Zu7KhHlpgTrkC5BQ0sw 9Wf7zXkf5KQ1g== From: Ard Biesheuvel To: linux-efi@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.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 , Xi Ruoyao , Lennart Poettering , Jeremy Linton , Will Deacon , Catalin Marinas Subject: [PATCH v5 6/8] arm64: efi: enable generic EFI compressed boot Date: Sat, 10 Sep 2022 10:11:50 +0200 Message-Id: <20220910081152.2238369-7-ardb@kernel.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20220910081152.2238369-1-ardb@kernel.org> References: <20220910081152.2238369-1-ardb@kernel.org> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=1642; i=ardb@kernel.org; h=from:subject; bh=GuY8276n/eRax8D4bN0N+JvUa77cwpfHICfgt9doQ1c=; b=owEB7QES/pANAwAKAcNPIjmS2Y8kAcsmYgBjHEbF8hJQ56ln/A/CC0taX3RBGiOeGIn/epSviNNT QJsSLjyJAbMEAAEKAB0WIQT72WJ8QGnJQhU3VynDTyI5ktmPJAUCYxxGxQAKCRDDTyI5ktmPJL8EDA CTUabsOcQV2xcWs4ccVK9JFyN0ArpMIc1LF7Ms9VYhLgxfPjQeZKNqdd2P7EU/Bvap6NsAwP85miC+ T5oXg9W6gGNd5hZ4bun9/72wXu1F1x+icitwh0nyFzeUcCUsaWpESFV9JWjgCKbewl3XIcmgDMqrlU O9GDST5OloaKjDFI2dhu1QeJYlqfclvyms/+AE9DOMvVWVEstMaTLvht0ols+p/82V0pdWxOB+oC7b zRfp+EZanT+oqL7CCIzqWQVPf3KIJaVhKTTd8PXduutM9t4C7+0o1W8RqLUrFHCVcLTJqGSP341sng 0Vd016ChIJqsNQxZUOBEPWODEyXmghiLCKNq3LHRXKoAy4tRg757PBPUzTtGtJ0B9wnnVDC1S2/pq8 Yqgqdul0Ge0ZCJgaRU9Su4iHwbbZObmaCGFh/t/BEhG9CKaK/s0J+cJNh3KBoD5MeLyovsbbh+KjKz lem/Xo2Av03S1nfBB+YA+AU2Gu/FIIrDR3AqsI2EdnH7k= X-Developer-Key: i=ardb@kernel.org; a=openpgp; fpr=F43D03328115A198C90016883D200E9CA6329909 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220910_011235_974314_D97A3A9E X-CRM114-Status: GOOD ( 11.36 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Wire up the generic EFI zboot support for arm64. Signed-off-by: Ard Biesheuvel --- arch/arm64/Makefile | 9 +++++++-- arch/arm64/boot/.gitignore | 1 + arch/arm64/boot/Makefile | 6 ++++++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/arch/arm64/Makefile b/arch/arm64/Makefile index 6d9d4a58b898..a82bb3599094 100644 --- a/arch/arm64/Makefile +++ b/arch/arm64/Makefile @@ -151,12 +151,17 @@ libs-$(CONFIG_EFI_STUB) += $(objtree)/drivers/firmware/efi/libstub/lib.a # Default target when executing plain make boot := arch/arm64/boot + +ifeq ($(CONFIG_EFI_ZBOOT),) KBUILD_IMAGE := $(boot)/Image.gz +else +KBUILD_IMAGE := $(boot)/vmlinuz.efi +endif -all: Image.gz +all: $(notdir $(KBUILD_IMAGE)) -Image: vmlinux +Image vmlinuz.efi: vmlinux $(Q)$(MAKE) $(build)=$(boot) $(boot)/$@ Image.%: Image diff --git a/arch/arm64/boot/.gitignore b/arch/arm64/boot/.gitignore index 9a7a9009d43a..af5dc61f8b43 100644 --- a/arch/arm64/boot/.gitignore +++ b/arch/arm64/boot/.gitignore @@ -1,3 +1,4 @@ # SPDX-License-Identifier: GPL-2.0-only Image Image.gz +vmlinuz* diff --git a/arch/arm64/boot/Makefile b/arch/arm64/boot/Makefile index a0e3dedd2883..c65aee088410 100644 --- a/arch/arm64/boot/Makefile +++ b/arch/arm64/boot/Makefile @@ -38,3 +38,9 @@ $(obj)/Image.lzo: $(obj)/Image FORCE $(obj)/Image.zst: $(obj)/Image FORCE $(call if_changed,zstd) + +EFI_ZBOOT_PAYLOAD := Image +EFI_ZBOOT_BFD_TARGET := elf64-littleaarch64 +EFI_ZBOOT_MACH_TYPE := ARM64 + +include $(srctree)/drivers/firmware/efi/libstub/Makefile.zboot -- 2.35.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel