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 phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 68750C46467 for ; Thu, 19 Jan 2023 17:41:49 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8D8E885673; Thu, 19 Jan 2023 18:41:34 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=kicherer.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=fail reason="signature verification failed" (1024-bit key; secure) header.d=kicherer.org header.i=@kicherer.org header.b="jjcd/hVF"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id C43C1851E6; Thu, 19 Jan 2023 16:28:39 +0100 (CET) Received: from mail.zeus06.de (www.zeus06.de [194.117.254.36]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 1EF4B8566F for ; Thu, 19 Jan 2023 16:28:36 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=kicherer.org Authentication-Results: phobos.denx.de; spf=none smtp.mailfrom=dev@kicherer.org DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=kicherer.org; h=from:to :cc:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; s=k1; bh=sWBbVeDUMEDRCf4g2++W/2X+aMD 9iqZ+1bXlLmKXmqo=; b=jjcd/hVFcJ8Yx01PxujlTw7MZKOl+L5pbqq8efjN2Qq fi+7tCXfoL0hLn0LBuQbi6ePcKL5iYFM4inwCKYWd0++ZKMXg4CPNhYL0oyOiOqN NUSeWpA/pFuWQzkZBEbMeYM3EAE8E+LwlUsWYBEPQpCyJoTMwN+78l76ts1kI/MQ = Received: (qmail 1972880 invoked from network); 19 Jan 2023 16:28:35 +0100 Received: by mail.zeus06.de with ESMTPSA (TLS_AES_256_GCM_SHA384 encrypted, authenticated); 19 Jan 2023 16:28:35 +0100 X-UD-Smtp-Session: l3s6476p2@2uPblZ/ynINd7WR9 From: Mario Kicherer To: u-boot@lists.denx.de Cc: sbabic@denx.de, festevam@gmail.com, uboot-imx@nxp.com, daniel.schwierzeck@gmail.com, weijie.gao@mediatek.com, GSS_MTK_Uboot_upstream@mediatek.com, rick@andestech.com, ycliang@andestech.com, Mario Kicherer Subject: [PATCH v2 1/2] spl: spl_nor: add BOOT_DEVICE_NOR2 as alternative SPL_LOAD_IMAGE_METHOD Date: Thu, 19 Jan 2023 16:28:21 +0100 Message-Id: <20230119152822.1214202-2-dev@kicherer.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230119152822.1214202-1-dev@kicherer.org> References: <20230119152822.1214202-1-dev@kicherer.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Mailman-Approved-At: Thu, 19 Jan 2023 18:41:30 +0100 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 Add BOOT_DEVICE_NOR2 as a second SPL_LOAD_IMAGE_METHOD to enable a board-specific spl_nor_get_uboot_base() function to return an alternative address in the NOR flash in case booting from BOOT_DEVICE_NOR fails. Signed-off-by: Mario Kicherer --- arch/arm/include/asm/spl.h | 1 + arch/mips/include/asm/spl.h | 1 + arch/riscv/include/asm/spl.h | 1 + common/spl/spl_nor.c | 1 + 4 files changed, 4 insertions(+) diff --git a/arch/arm/include/asm/spl.h b/arch/arm/include/asm/spl.h index 0ece4b0906..3ca4b95713 100644 --- a/arch/arm/include/asm/spl.h +++ b/arch/arm/include/asm/spl.h @@ -20,6 +20,7 @@ enum { BOOT_DEVICE_NAND, BOOT_DEVICE_ONENAND, BOOT_DEVICE_NOR, + BOOT_DEVICE_NOR2, BOOT_DEVICE_UART, BOOT_DEVICE_SPI, BOOT_DEVICE_USB, diff --git a/arch/mips/include/asm/spl.h b/arch/mips/include/asm/spl.h index 0a847edec8..a3b20ac98f 100644 --- a/arch/mips/include/asm/spl.h +++ b/arch/mips/include/asm/spl.h @@ -14,6 +14,7 @@ enum { BOOT_DEVICE_NAND, BOOT_DEVICE_ONENAND, BOOT_DEVICE_NOR, + BOOT_DEVICE_NOR2, BOOT_DEVICE_UART, BOOT_DEVICE_SPI, BOOT_DEVICE_USB, diff --git a/arch/riscv/include/asm/spl.h b/arch/riscv/include/asm/spl.h index 2898a770ee..8d7a25be33 100644 --- a/arch/riscv/include/asm/spl.h +++ b/arch/riscv/include/asm/spl.h @@ -16,6 +16,7 @@ enum { BOOT_DEVICE_NAND, BOOT_DEVICE_ONENAND, BOOT_DEVICE_NOR, + BOOT_DEVICE_NOR2, BOOT_DEVICE_UART, BOOT_DEVICE_SPI, BOOT_DEVICE_USB, diff --git a/common/spl/spl_nor.c b/common/spl/spl_nor.c index 3ca44b06d6..5e8b3bf621 100644 --- a/common/spl/spl_nor.c +++ b/common/spl/spl_nor.c @@ -123,3 +123,4 @@ static int spl_nor_load_image(struct spl_image_info *spl_image, return 0; } SPL_LOAD_IMAGE_METHOD("NOR", 0, BOOT_DEVICE_NOR, spl_nor_load_image); +SPL_LOAD_IMAGE_METHOD("NOR2", 0, BOOT_DEVICE_NOR2, spl_nor_load_image); -- 2.34.1