From patchwork Tue Dec 6 02:33:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marek Vasut X-Patchwork-Id: 1712511 X-Patchwork-Delegate: patrice.chotard@st.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=denx.de header.i=@denx.de header.a=rsa-sha256 header.s=phobos-20191101 header.b=ox7aRXyL; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.a=rsa-sha256 header.s=phobos-20191101 header.b=KJrb1pXz; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4NR4JH5ZQrz23ns for ; Tue, 6 Dec 2022 13:34:55 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 87715854F0; Tue, 6 Dec 2022 03:34:27 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1670294067; bh=QpdSu2aJLlD7U72fliKlV6hLZ/q5/iuOnRdRBNCGFI4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=ox7aRXyLwyBtn/73gDh7uyMlq39oVE4v2ygQae6IQvTnBFlcFU4uZ3Whl3BRvstdj rEJiSPSWpiYwAifSOyraPNQooSgs6FCCzCujOcfRc08P0XiPkdbeaBCXMLQ2Z+RxPH miPlSpQI0JDsUxG8NGIe4fD04VzpY0ms0VBRg6KVWCxLENsNVKXV1x7vXMVZMIkeKj rDQsTJTARYg+ak1cu6ujZtcLexByTgbpDY/UkUyRJItzinz681CB70PVaC968cAVqm QymRw939NvztjmlNbtcr+Hc1KCpgaOUUq+IZysnsbRgFcC0b79Wrh2ux6Oq2S30Ncg ceUXywtNcml5w== Received: from tr.lan (ip-86-49-120-218.bb.vodafone.cz [86.49.120.218]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) (Authenticated sender: marex@denx.de) by phobos.denx.de (Postfix) with ESMTPSA id 5B8488523F; Tue, 6 Dec 2022 03:34:15 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1670294055; bh=QpdSu2aJLlD7U72fliKlV6hLZ/q5/iuOnRdRBNCGFI4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KJrb1pXzo+ufgv7DkknPlYBOhapeDr05ccDar2Q6gLINSG3Bm9jOz/Vt/0nxO8xKr Ygg9RAyb6mbUkt5ubPx2Djte41tnJ7dogYmesv6lp1A/XfteUse7oRakzmWuAkHQUb lWxAQBO0ypmrY+LaZKUSvmCia0WR8944/BueAu75HWzS/OTfjnBSPcW8jmgdmVEIQ+ uit3teUbrobp20QjexHVU+az3bQTWsq163zx3kSFuALgyZs/4Gb+4IqI+8hz+6ueyb 0VFSLpmO7EmjSu5JUX9H/DrtCB2BKJ4gpJNPPjymdCnBP7usaZjG8z8FivUdxRO/Wy +G+ietTbnXNxQ== From: Marek Vasut To: u-boot@lists.denx.de Cc: Marek Vasut , Alexandru Gagniuc , Patrice Chotard , Patrick Delaunay Subject: [PATCH 4/4] ARM: stm32: Make ECDSA authentication available to U-Boot Date: Tue, 6 Dec 2022 03:33:57 +0100 Message-Id: <20221206023357.113361-4-marex@denx.de> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221206023357.113361-1-marex@denx.de> References: <20221206023357.113361-1-marex@denx.de> MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean With U-Boot having access to ROM API call table, it is possible to use the ROM API call it authenticate e.g. signed kernel fitImages using the BootROM ECDSA support. Make this available by pulling the ECDSA BootROM call support from SPL-only guard. Signed-off-by: Marek Vasut Reviewed-by: Patrice Chotard Reviewed-by: Patrick Delaunay --- Cc: Alexandru Gagniuc Cc: Patrice Chotard Cc: Patrick Delaunay --- arch/arm/mach-stm32mp/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-stm32mp/Makefile b/arch/arm/mach-stm32mp/Makefile index 1db9057e049..a19b2797c8b 100644 --- a/arch/arm/mach-stm32mp/Makefile +++ b/arch/arm/mach-stm32mp/Makefile @@ -11,10 +11,10 @@ obj-y += bsec.o obj-$(CONFIG_STM32MP13x) += stm32mp13x.o obj-$(CONFIG_STM32MP15x) += stm32mp15x.o +obj-$(CONFIG_STM32_ECDSA_VERIFY) += ecdsa_romapi.o ifdef CONFIG_SPL_BUILD obj-y += spl.o obj-y += tzc400.o -obj-$(CONFIG_STM32_ECDSA_VERIFY) += ecdsa_romapi.o else obj-y += cmd_stm32prog/ obj-$(CONFIG_CMD_STM32KEY) += cmd_stm32key.o