From patchwork Mon Sep 27 06:47:46 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilias Apalodimas X-Patchwork-Id: 514659 Delivered-To: patch@linaro.org Received: by 2002:a02:c816:0:0:0:0:0 with SMTP id p22csp3839846jao; Sun, 26 Sep 2021 23:48:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxEycvSOdgK3EZVL1uE/sBfWoHMBKuMiU8lx7Z31apDrxkDUY6rL7yn/DYrbJF6QmEoJgSf X-Received: by 2002:a17:906:38db:: with SMTP id r27mr25342694ejd.338.1632725298583; Sun, 26 Sep 2021 23:48:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632725298; cv=none; d=google.com; s=arc-20160816; b=lFyMbLlo7FqmhvN1lr5hIGayhNJyNIfzhXc+F9WyOGabyb1ZBmMYr3UdxiuHOblk/C AgGxWtoW/iLLMDphflR1JtrLP2xpfLruWw6YSnsKi6VX+kDBXmiy4VsENgi8dCLycWS3 NU4Hiyh7lqr9Zthw80eQkMTDwomO9lNd8cwgcSnAkqWuSaQlXMAl1DiuQ5Q6R/bIGJoo 1Y0xmcyRGrCx5ufGxY247qoxKmaRdCFK/XUkQx6XVY7RRHbM4CdtVuaPjgE8eOQNgZoy 4MdhplNracIt71SB4c3C5DuvEk5m1jvd0FrmNYwXDrwuVrgVA/6OqJyKbOgWPPFrgXNp GSBg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=YSIPKu7T9Kj4ZFTi9M1SfgN8Z0i8iuoyZtfpXXz/fz0=; b=bywHIJxuwG0nIUkNy5dBW0BroWjYuL8ZZ+4LGRH8S3RgHP2SNVkRCORkuycvs8ouJ4 MI9o3dBAqgoqyTXzX/MvM5Rq2yQgeLkEDiduOdgSbuGAg8NE7K9whzF62gDSeBiB5iDb 6seCeXbU2GuCzMR4N5s3artbAkf+ZcIvWoIn/15+cI9sgSOhGySHekLS0/uKcWCmN8Gt o/UDzlTX5VQiFrzmSJBN09e0D3CMVnYCUqiqOT/8L6EXRLtLzN6Fg0yv8sDWmCR6Zs6p WyCCg7dH/mxfn8xufbnYxLt3H40r2zpb7HMDGZ5aBKECpeaZTC4eg+0ohEf5XZ1QrzEv QXTg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Rwzv2GKf; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id bg4si9559857ejb.452.2021.09.26.23.48.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Sep 2021 23:48:18 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Rwzv2GKf; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 373DF835B9; Mon, 27 Sep 2021 08:48:14 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="Rwzv2GKf"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id D37D98357A; Mon, 27 Sep 2021 08:48:11 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ed1-x534.google.com (mail-ed1-x534.google.com [IPv6:2a00:1450:4864:20::534]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 8B8498348D for ; Mon, 27 Sep 2021 08:48:07 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=ilias.apalodimas@linaro.org Received: by mail-ed1-x534.google.com with SMTP id x7so50227171edd.6 for ; Sun, 26 Sep 2021 23:48:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=YSIPKu7T9Kj4ZFTi9M1SfgN8Z0i8iuoyZtfpXXz/fz0=; b=Rwzv2GKfaR+NvKc9sby0bKD0hZA4LkdwNI7LozLjpVbKyWxaCbG5A/g2VPcSLHzBQ0 pywjo2W00qHQOZWZgfC2kxZfHgjqFrZxyz2pesPXE3Rpc/qzeG/afFVSg6LoLfP39/08 06su4A7L8JjbnYOIhVvm8v45iwx9UIUnMKeWoUAycvfO/m62nmgzouoT/o9cR4T75rJM q1lOkkrWgP7lfPZuQJbmnfR913Sqk/+1VQg2kXHQTkQZzFAdSPa6l8fg9gOT3uyanyHi fULHAJboXehP2tUogQVNPfrPHzrkG5SdvgI3Exxn47yolWSZOOa58O4k5YDdkM82cin5 AmJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=YSIPKu7T9Kj4ZFTi9M1SfgN8Z0i8iuoyZtfpXXz/fz0=; b=zs4yLK8k+Chuic16/7uvFnCn+tx40DOzbLMCmA5/MzzMte53SmoTMD23J0hQivGVXn bGXDpiG0FA0rSJ8t4xzfSbAavv78l7pghBWVcCgBNTZD1RhM6xlmCZ7f4RTJPOuY1p/4 rrwDxMhlCoSOFacMNH31jcV1XLZ0UrAXICGEk4C2wRux5FZBhECVe77RBBYYUo8VcmFO nAUv7bU/WeG1xgESucaW325l7D8GKriQ846o1dhDsCDe/Caw57WpBGBHdBZEO6wXqwH/ smqErUnsbGh0P1k/KdM3tGSJLYkZDc7KbUW9wZCJ8jcalr3vJ/IZkJdMmj1AWwElyoka h3Kg== X-Gm-Message-State: AOAM530cfiPXHc1GwEbJ7cJ2yIWsFXM4Nh5iSK7sirFMeuXuyNbpjb/x PTNXqfmAbip+AD6u0Flnh905GA== X-Received: by 2002:a05:6402:2682:: with SMTP id w2mr4538290edd.62.1632725287128; Sun, 26 Sep 2021 23:48:07 -0700 (PDT) Received: from apalos.home ([2a02:587:4672:866:2e56:dcff:fe9a:8f06]) by smtp.gmail.com with ESMTPSA id dm8sm9948398edb.90.2021.09.26.23.48.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Sep 2021 23:48:06 -0700 (PDT) From: Ilias Apalodimas To: trini@konsulko.com Cc: mark.kettenis@xs4all.nl, Ilias Apalodimas , Bharat Gooty , Rayagonda Kokatanur , Rick Chen , Leo , Thomas Fitzsimmons , Simon Glass , Bin Meng , =?utf-8?q?Marek_Beh=C3=BAn?= , Green Wan , Sean Anderson , Lukas Auer , Brad Kim , Zong Li , Heinrich Schuchardt , David Abdurachmanov , Dimitri John Ledkov , u-boot@lists.denx.de Subject: [PATCH 1/3] treewide: Remove OF_PRIOR_STAGE from RISC-V boards Date: Mon, 27 Sep 2021 09:47:46 +0300 Message-Id: <20210927064751.78591-1-ilias.apalodimas@linaro.org> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean At some point back in 2018 prior_stage_fdt_address and OF_PRIOR_STAGE got introduced, in order to support a DTB handed over by an earlier stage boo loader. However we have another option in the Kconfig (OF_BOARD) which has identical semantics. On RISC-V boards which during their startup, some of the platforms, pick up the DTB from a1 and copy it in their private gd_t. Apart from that they copy it to prior_stage_fdt_address, if the Kconfig option is selected, which is unnecessary. So let's switch the config option for those boards to OF_BOARD and define the required board_fdt_blob_setup() for them. Signed-off-by: Ilias Apalodimas --- arch/riscv/cpu/cpu.c | 3 --- arch/riscv/cpu/start.S | 5 ----- arch/riscv/dts/binman.dtsi | 6 +++--- board/AndesTech/ax25-ae350/ax25-ae350.c | 1 - board/emulation/qemu-riscv/qemu-riscv.c | 9 +++++++++ board/sifive/unleashed/unleashed.c | 10 ++++------ board/sifive/unmatched/unmatched.c | 10 ++++------ configs/ae350_rv32_defconfig | 2 +- configs/ae350_rv32_spl_defconfig | 2 +- configs/ae350_rv64_defconfig | 2 +- configs/ae350_rv64_spl_defconfig | 2 +- configs/qemu-riscv32_defconfig | 2 +- configs/qemu-riscv32_smode_defconfig | 2 +- configs/qemu-riscv32_spl_defconfig | 2 +- configs/qemu-riscv64_defconfig | 2 +- configs/qemu-riscv64_smode_defconfig | 2 +- configs/qemu-riscv64_spl_defconfig | 2 +- dts/Kconfig | 2 +- 18 files changed, 31 insertions(+), 35 deletions(-) -- 2.33.0 Reviewed-by: Simon Glass diff --git a/arch/riscv/cpu/cpu.c b/arch/riscv/cpu/cpu.c index c894ac10b536..e16f1df30254 100644 --- a/arch/riscv/cpu/cpu.c +++ b/arch/riscv/cpu/cpu.c @@ -16,9 +16,6 @@ * The variables here must be stored in the data section since they are used * before the bss section is available. */ -#ifdef CONFIG_OF_PRIOR_STAGE -phys_addr_t prior_stage_fdt_address __section(".data"); -#endif #ifndef CONFIG_XIP u32 hart_lottery __section(".data") = 0; diff --git a/arch/riscv/cpu/start.S b/arch/riscv/cpu/start.S index 308b0a97a58f..76850ec9be2c 100644 --- a/arch/riscv/cpu/start.S +++ b/arch/riscv/cpu/start.S @@ -142,11 +142,6 @@ call_harts_early_init: bnez tp, secondary_hart_loop #endif -#ifdef CONFIG_OF_PRIOR_STAGE - la t0, prior_stage_fdt_address - SREG s1, 0(t0) -#endif - jal board_init_f_init_reserve SREG s1, GD_FIRMWARE_FDT_ADDR(gp) diff --git a/arch/riscv/dts/binman.dtsi b/arch/riscv/dts/binman.dtsi index d26cfdb78a9e..5757ef65ea4b 100644 --- a/arch/riscv/dts/binman.dtsi +++ b/arch/riscv/dts/binman.dtsi @@ -48,7 +48,7 @@ }; }; -#ifndef CONFIG_OF_PRIOR_STAGE +#ifndef CONFIG_OF_BOARD @fdt-SEQ { description = "NAME"; type = "flat_dt"; @@ -60,7 +60,7 @@ configurations { default = "conf-1"; -#ifndef CONFIG_OF_PRIOR_STAGE +#ifndef CONFIG_OF_BOARD @conf-SEQ { #else conf-1 { @@ -68,7 +68,7 @@ description = "NAME"; firmware = "opensbi"; loadables = "uboot"; -#ifndef CONFIG_OF_PRIOR_STAGE +#ifndef CONFIG_OF_BOARD fdt = "fdt-SEQ"; #endif }; diff --git a/board/AndesTech/ax25-ae350/ax25-ae350.c b/board/AndesTech/ax25-ae350/ax25-ae350.c index 81b0ee992372..4f03806272df 100644 --- a/board/AndesTech/ax25-ae350/ax25-ae350.c +++ b/board/AndesTech/ax25-ae350/ax25-ae350.c @@ -21,7 +21,6 @@ DECLARE_GLOBAL_DATA_PTR; -extern phys_addr_t prior_stage_fdt_address; /* * Miscellaneous platform dependent initializations */ diff --git a/board/emulation/qemu-riscv/qemu-riscv.c b/board/emulation/qemu-riscv/qemu-riscv.c index dcfd3f20bee6..aa91ca91325c 100644 --- a/board/emulation/qemu-riscv/qemu-riscv.c +++ b/board/emulation/qemu-riscv/qemu-riscv.c @@ -14,6 +14,8 @@ #include #include +DECLARE_GLOBAL_DATA_PTR; + int board_init(void) { /* @@ -69,3 +71,10 @@ int board_fit_config_name_match(const char *name) return 0; } #endif + +void *board_fdt_blob_setup(void) +{ + /* Stored the DTB address there during our init */ + return (void *)gd->arch.firmware_fdt_addr; +} + diff --git a/board/sifive/unleashed/unleashed.c b/board/sifive/unleashed/unleashed.c index 8cd514df3005..7e89c3f740a7 100644 --- a/board/sifive/unleashed/unleashed.c +++ b/board/sifive/unleashed/unleashed.c @@ -116,12 +116,10 @@ int misc_init_r(void) void *board_fdt_blob_setup(void) { - if (IS_ENABLED(CONFIG_OF_SEPARATE)) { - if (gd->arch.firmware_fdt_addr) - return (ulong *)gd->arch.firmware_fdt_addr; - else - return (ulong *)&_end; - } + if (gd->arch.firmware_fdt_addr) + return (void *)gd->arch.firmware_fdt_addr; + else + return (void *)&_end; } int board_init(void) diff --git a/board/sifive/unmatched/unmatched.c b/board/sifive/unmatched/unmatched.c index d90b252baef7..2f26f92fcb2b 100644 --- a/board/sifive/unmatched/unmatched.c +++ b/board/sifive/unmatched/unmatched.c @@ -13,12 +13,10 @@ void *board_fdt_blob_setup(void) { - if (IS_ENABLED(CONFIG_OF_SEPARATE)) { - if (gd->arch.firmware_fdt_addr) - return (ulong *)gd->arch.firmware_fdt_addr; - else - return (ulong *)&_end; - } + if (gd->arch.firmware_fdt_addr) + return (void *)gd->arch.firmware_fdt_addr; + else + return (void *)&_end; } int board_init(void) diff --git a/configs/ae350_rv32_defconfig b/configs/ae350_rv32_defconfig index 4e7a1686a64d..8b6c0b8a4a0a 100644 --- a/configs/ae350_rv32_defconfig +++ b/configs/ae350_rv32_defconfig @@ -15,7 +15,7 @@ CONFIG_CMD_SF_TEST=y # CONFIG_CMD_SETEXPR is not set CONFIG_BOOTP_PREFER_SERVERIP=y CONFIG_CMD_CACHE=y -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y diff --git a/configs/ae350_rv32_spl_defconfig b/configs/ae350_rv32_spl_defconfig index 34c6af6e7e17..a0fe9b9a71df 100644 --- a/configs/ae350_rv32_spl_defconfig +++ b/configs/ae350_rv32_spl_defconfig @@ -19,7 +19,7 @@ CONFIG_CMD_SF_TEST=y # CONFIG_CMD_SETEXPR is not set CONFIG_BOOTP_PREFER_SERVERIP=y CONFIG_CMD_CACHE=y -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTP_SEND_HOSTNAME=y diff --git a/configs/ae350_rv64_defconfig b/configs/ae350_rv64_defconfig index 05eee371ac2f..cb23cbd3d95e 100644 --- a/configs/ae350_rv64_defconfig +++ b/configs/ae350_rv64_defconfig @@ -16,7 +16,7 @@ CONFIG_CMD_SF_TEST=y # CONFIG_CMD_SETEXPR is not set CONFIG_BOOTP_PREFER_SERVERIP=y CONFIG_CMD_CACHE=y -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y diff --git a/configs/ae350_rv64_spl_defconfig b/configs/ae350_rv64_spl_defconfig index 9cd7848c92eb..9ad312505db3 100644 --- a/configs/ae350_rv64_spl_defconfig +++ b/configs/ae350_rv64_spl_defconfig @@ -20,7 +20,7 @@ CONFIG_CMD_SF_TEST=y # CONFIG_CMD_SETEXPR is not set CONFIG_BOOTP_PREFER_SERVERIP=y CONFIG_CMD_CACHE=y -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_BOOTP_SEND_HOSTNAME=y diff --git a/configs/qemu-riscv32_defconfig b/configs/qemu-riscv32_defconfig index 8ac16cf4186e..6fe133c268d7 100644 --- a/configs/qemu-riscv32_defconfig +++ b/configs/qemu-riscv32_defconfig @@ -9,6 +9,6 @@ CONFIG_DISPLAY_BOARDINFO=y CONFIG_CMD_BOOTEFI_SELFTEST=y CONFIG_CMD_NVEDIT_EFI=y # CONFIG_CMD_MII is not set -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_DM_MTD=y diff --git a/configs/qemu-riscv32_smode_defconfig b/configs/qemu-riscv32_smode_defconfig index 05eda439618f..c67e8206d1ab 100644 --- a/configs/qemu-riscv32_smode_defconfig +++ b/configs/qemu-riscv32_smode_defconfig @@ -10,6 +10,6 @@ CONFIG_DISPLAY_BOARDINFO=y CONFIG_CMD_BOOTEFI_SELFTEST=y CONFIG_CMD_NVEDIT_EFI=y # CONFIG_CMD_MII is not set -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_DM_MTD=y diff --git a/configs/qemu-riscv32_spl_defconfig b/configs/qemu-riscv32_spl_defconfig index ee81e552724d..77e81fac3af7 100644 --- a/configs/qemu-riscv32_spl_defconfig +++ b/configs/qemu-riscv32_spl_defconfig @@ -12,6 +12,6 @@ CONFIG_DISPLAY_CPUINFO=y CONFIG_DISPLAY_BOARDINFO=y CONFIG_CMD_SBI=y # CONFIG_CMD_MII is not set -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_DM_MTD=y diff --git a/configs/qemu-riscv64_defconfig b/configs/qemu-riscv64_defconfig index daf5d655d01f..90e87672aab0 100644 --- a/configs/qemu-riscv64_defconfig +++ b/configs/qemu-riscv64_defconfig @@ -10,6 +10,6 @@ CONFIG_DISPLAY_BOARDINFO=y CONFIG_CMD_BOOTEFI_SELFTEST=y CONFIG_CMD_NVEDIT_EFI=y # CONFIG_CMD_MII is not set -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_DM_MTD=y diff --git a/configs/qemu-riscv64_smode_defconfig b/configs/qemu-riscv64_smode_defconfig index 4a6416e2540b..0a8393903368 100644 --- a/configs/qemu-riscv64_smode_defconfig +++ b/configs/qemu-riscv64_smode_defconfig @@ -13,6 +13,6 @@ CONFIG_DISPLAY_BOARDINFO=y CONFIG_CMD_BOOTEFI_SELFTEST=y CONFIG_CMD_NVEDIT_EFI=y # CONFIG_CMD_MII is not set -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_DM_MTD=y diff --git a/configs/qemu-riscv64_spl_defconfig b/configs/qemu-riscv64_spl_defconfig index 429d4d814e65..a15e82dd3ee1 100644 --- a/configs/qemu-riscv64_spl_defconfig +++ b/configs/qemu-riscv64_spl_defconfig @@ -13,6 +13,6 @@ CONFIG_DISPLAY_CPUINFO=y CONFIG_DISPLAY_BOARDINFO=y CONFIG_CMD_SBI=y # CONFIG_CMD_MII is not set -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_DM_MTD=y diff --git a/dts/Kconfig b/dts/Kconfig index dabe0080c1ef..39270b47f9f0 100644 --- a/dts/Kconfig +++ b/dts/Kconfig @@ -107,7 +107,7 @@ config OF_EMBED Boards in the mainline U-Boot tree should not use it. config OF_BOARD - bool "Provided by the board at runtime" + bool "Provided by the board (e.g a previous loader) at runtime" depends on !SANDBOX help If this option is enabled, the device tree will be provided by From patchwork Mon Sep 27 06:47:47 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilias Apalodimas X-Patchwork-Id: 514660 Delivered-To: patch@linaro.org Received: by 2002:a02:c816:0:0:0:0:0 with SMTP id p22csp3839963jao; Sun, 26 Sep 2021 23:48:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw8q2S00R5gifc8BBZc+diJ7Sw1mBfRLnIVvm53OdJPhD3D4qmfoDPtDvSkEk4uTAfgzU9P X-Received: by 2002:a17:906:8a41:: with SMTP id gx1mr26421692ejc.507.1632725311636; Sun, 26 Sep 2021 23:48:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632725311; cv=none; d=google.com; s=arc-20160816; b=Z6UGmkgoHA8EGEeV84uw94gNA19IiQL4ND3WZYHZ/26u71pg31KTrUKlJ8c3wuMPRf GZ9sY0OSDvUWn+gCwGrR2UkjRRbCcOfYCXx0STqFaIiXSJehsziWUlxFmbvM8bKmKVDQ wQJWJMCR3utDZBzw6q6kcLc8jaLnYfjpusKw01w3/IQyITnkGukJ/WE7EHDpYxG+80/m mXfJg1KuCwz2kJdU2v05ZOWC936kA7zGzSlX0P/U3utWfWrC/5g6r4+HddO3oh7I10vt 0PzuKQAtIGG4V+m5NSgzUTP08cvLWfro0WG1w5u4dW1O2OBbjLFwm5nV6uF7cRpNdf3Z EWBA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=83usUrQjmZxne/CWTarHpix9cEZnc17PgtJJGxyVz64=; b=Ke2BIWRca/gs3cu1BAUFHxrTyli9gDGSGjpUEZ2uAluhDf2l9+4T4Q2A51Sp9O4f4Q PWnnr6Bjp1sJXHevYmGJZfD1BUg6iuznmV0oE4Ip58Q2UMg20Sd4xl5xfzDDPGfaXlRG pvg1w+WbVzSXW07uzQfEo9fyCRDBKdo/2E7KFy4DEfv1f9x9xrRz4BfMejZzHndoNqFB Ce1UgqFMo/IGZ2Wxh/ANBWTlkv3ZFO5zqnhiWTTHP1AWkYve5D7ZxV/p/Lciv4zkn4ZG yezCbyzXJCzucQZACLsavc+ETPnQx4Zi6nh8Ww1BzGfwoCeQk0UdCgvknz4IMaH89gvY RNTQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RVuk3bOi; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id h9si13689181edb.422.2021.09.26.23.48.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Sep 2021 23:48:31 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RVuk3bOi; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 75AC483605; Mon, 27 Sep 2021 08:48:24 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="RVuk3bOi"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 58D9E8348D; Mon, 27 Sep 2021 08:48:17 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ed1-x52d.google.com (mail-ed1-x52d.google.com [IPv6:2a00:1450:4864:20::52d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id BA4598348D for ; Mon, 27 Sep 2021 08:48:12 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=ilias.apalodimas@linaro.org Received: by mail-ed1-x52d.google.com with SMTP id ee50so64964091edb.13 for ; Sun, 26 Sep 2021 23:48:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=83usUrQjmZxne/CWTarHpix9cEZnc17PgtJJGxyVz64=; b=RVuk3bOijD4GeLxLSVD1K0GMxnbOLUTU6xldtnIvjQ95q18GmS65yAc8nw3ytwYFgO BuqYWqHnjCPAYY51RpParcjvHYYT7nZKrA563483TK00g5CgsRyImLHmNFmdjs4eEFlO s/Sjz7XRfJMYDB0zZW3HtQuQQmzp7eG399kEPPUb6yU2fhRUB1yf//5qsbl1Y+w5T/tm jgxnBnLdPhWFddcOOKd47RD0T5DIJ2MGMQ4tgCew+BRKwfP+QZIVLwHR/+aTNbKrWLDy ranOfpEwe3u0D3oSq26xOd0/hktfhvTZ3SZGbeOsYjcKhRPzcHVfUryoa9BUVeL08ypo fb5g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=83usUrQjmZxne/CWTarHpix9cEZnc17PgtJJGxyVz64=; b=VJ0HUgif+nk2kXCT7Z9UzmhQ7TOpRtO9qIMGlUX7B63y2gLwd1yMmrjr5Za4LnU3Yf kInDJb8Nc19jcvslMqnm3BjkN6PFiSlm/ZVLGaPLJ2pns+d8aVK4riNBg/qzoe3adZb0 /wAHrSHOPuLWjws3Nimp/Xxp01KZc9Lo9IIN1s3GcILlPNl7w0/MMxVgN8+dtgX+E/MH K72NNQRgL8qs5N8LQmOsNfWCcRkdJr9+onJrp4Wyy/Qz+NQsvD8K3dkcee72BHsc1gvE JkQOlwbih5ZRdnai72fX+5CKjm83zzwq8PDz6HwtCMQQCbgFQnikGq2UmoDCHmz1WyeI hDpQ== X-Gm-Message-State: AOAM530eWU9vM+HD+g+pXpgAUVh8Sedem7mbUPPGDu8+3RP8lPcBISIe ik02Nq0gsNptLhnz9rKar/d0XQ== X-Received: by 2002:a17:906:2505:: with SMTP id i5mr25313020ejb.450.1632725292398; Sun, 26 Sep 2021 23:48:12 -0700 (PDT) Received: from apalos.home ([2a02:587:4672:866:2e56:dcff:fe9a:8f06]) by smtp.gmail.com with ESMTPSA id dm8sm9948398edb.90.2021.09.26.23.48.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Sep 2021 23:48:12 -0700 (PDT) From: Ilias Apalodimas To: trini@konsulko.com Cc: mark.kettenis@xs4all.nl, Ilias Apalodimas , Bharat Gooty , Rayagonda Kokatanur , Rick Chen , Leo , Thomas Fitzsimmons , Simon Glass , Bin Meng , Sean Anderson , Green Wan , =?utf-8?q?Marek_Beh=C3=BAn?= , Brad Kim , Zong Li , Heinrich Schuchardt , David Abdurachmanov , Dimitri John Ledkov , u-boot@lists.denx.de Subject: [PATCH 2/3] board: arm: Remove OF_PRIOR_STAGE Date: Mon, 27 Sep 2021 09:47:47 +0300 Message-Id: <20210927064751.78591-2-ilias.apalodimas@linaro.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210927064751.78591-1-ilias.apalodimas@linaro.org> References: <20210927064751.78591-1-ilias.apalodimas@linaro.org> MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean At some point back in 2018 prior_stage_fdt_address and OF_PRIOR_STAGE got introduced, in order to support a DTB handed over by an earlier stage boo loader. However we have another option in the Kconfig (OF_BOARD) which has identical semantics. So let's remove the option in an effort to simplify U-Boot's config and DTB management, and use OF_BOARD instead. Signed-off-by: Ilias Apalodimas --- arch/arm/Kconfig | 1 - board/broadcom/bcmstb/bcmstb.c | 6 ++++++ configs/bcm7260_defconfig | 2 +- configs/bcm7445_defconfig | 2 +- 4 files changed, 8 insertions(+), 3 deletions(-) -- 2.33.0 Reviewed-by: Simon Glass diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index b5bd3284cd1c..8bc4391fcb27 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -620,7 +620,6 @@ config ARCH_BCMSTB select DM select GPIO_EXTRA_HEADER select OF_CONTROL - select OF_PRIOR_STAGE imply CMD_DM help This enables support for Broadcom ARM-based set-top box diff --git a/board/broadcom/bcmstb/bcmstb.c b/board/broadcom/bcmstb/bcmstb.c index 076ac9414418..40d9def24b7b 100644 --- a/board/broadcom/bcmstb/bcmstb.c +++ b/board/broadcom/bcmstb/bcmstb.c @@ -135,3 +135,9 @@ int board_late_init(void) return 0; } + +void *board_fdt_blob_setup(void) +{ + /* Stored the DTB address there during our init */ + return (void *)prior_stage_fdt_address; +} diff --git a/configs/bcm7260_defconfig b/configs/bcm7260_defconfig index a42a6acb06d5..be0c945dc811 100644 --- a/configs/bcm7260_defconfig +++ b/configs/bcm7260_defconfig @@ -22,7 +22,7 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_FS_GENERIC=y -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_MMC=y CONFIG_SYS_REDUNDAND_ENVIRONMENT=y diff --git a/configs/bcm7445_defconfig b/configs/bcm7445_defconfig index 96e8da0748ae..9ab72dcf37c7 100644 --- a/configs/bcm7445_defconfig +++ b/configs/bcm7445_defconfig @@ -23,7 +23,7 @@ CONFIG_CMD_CACHE=y CONFIG_CMD_EXT2=y CONFIG_CMD_EXT4=y CONFIG_CMD_FS_GENERIC=y -CONFIG_OF_PRIOR_STAGE=y +CONFIG_OF_BOARD=y CONFIG_ENV_OVERWRITE=y CONFIG_ENV_IS_IN_SPI_FLASH=y CONFIG_SYS_REDUNDAND_ENVIRONMENT=y From patchwork Mon Sep 27 06:47:48 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilias Apalodimas X-Patchwork-Id: 514661 Delivered-To: patch@linaro.org Received: by 2002:a02:c816:0:0:0:0:0 with SMTP id p22csp3840051jao; Sun, 26 Sep 2021 23:48:42 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxxa6nftxpol8ts3Kj8uw094RGu04VpifUb2ERGeDsc3aOzlh2QV42mgUocX4O8oM2dy34G X-Received: by 2002:a17:906:b80b:: with SMTP id dv11mr26617962ejb.156.1632725322599; Sun, 26 Sep 2021 23:48:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632725322; cv=none; d=google.com; s=arc-20160816; b=KIPPxkbWIIQ4/CwJJ/tzJ0uTV43jbM+h4oDKUruFywM1phdTEXxcr1R/YTbj+u32+H sOqLm4lmID1bz6F+oFeabJAMbsJz2qSjzCqIahMWZcUkxFIIvV9l1/kdJEJGdmg81mRi YGWjpcxrqQ7ZSMxSUn5UMsfQAICuG8kstv74BM97rK27+bIixSxRO+PFD/oB62FhDkok rKwyVAvn3lNlnJ64UXZuZpBbuxUQOaBfmP6MylBssb8y350sW3ovBng2jYyXdd63wmbm crDgUEST6TrFi8d4fmb97mt1F62lAevqZZhOG7OeEq6GKpe23kA2RlA3FuBuestg3vq5 ybyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=Z/+PShzHeuWeSQbVu69qWjybFwLZgWZYSy7GBE68WGo=; b=uFDmWSYA5v3UdLDXUSEHLHF8YkLeiN/HtOwKRoyf7eLQSHnjEQVussWn5r8pIpgaKG R/Q6gaZlJQMg0w0yq7zrZu9+F6Y+Vv216b32ogZpRo5lvjZv4zX5rQz5Y6WPljXSpDGG wkOeSTiMfxiTM9PZBgzZtJ/7XiKNjRyFSfOvcSFGKtqzSjYkQzLDcG4eCAFCQAZMnKCr ujvC2U//PKrSRmbbt8DG8qBj5+Pc+0C9REy88sQGvemJwQiHzNFeDWZbQOKzpLYVuJMX 8vy2hh4bQ0Trr6NCCR5LQo5FL7mXD/GwbnD4n5C5JyCznu/J2AyZQzEYGFg+UOS+wsPY iyZw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Ug4UmjId; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id d12si15957315edx.464.2021.09.26.23.48.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Sep 2021 23:48:42 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=Ug4UmjId; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 5F8C9835FB; Mon, 27 Sep 2021 08:48:36 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="Ug4UmjId"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id DE7EB835F3; Mon, 27 Sep 2021 08:48:23 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ed1-x529.google.com (mail-ed1-x529.google.com [IPv6:2a00:1450:4864:20::529]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 7F5438348D for ; Mon, 27 Sep 2021 08:48:18 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=ilias.apalodimas@linaro.org Received: by mail-ed1-x529.google.com with SMTP id g8so64906235edt.7 for ; Sun, 26 Sep 2021 23:48:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Z/+PShzHeuWeSQbVu69qWjybFwLZgWZYSy7GBE68WGo=; b=Ug4UmjIdWY9u0Vl2g286VPFpoOaI5fw9WJtnu2O+4qcLU1CJN0q+b7QQlTXDUUrl3e kAVwCiqdCfBUVX+5yekujqeq2Twy9YJRjJGQZI1ehW6bakoKCM7mm3K+Mzn3jL9unrBd fKDAQGoK2sM08k7IqdvfvwKJ5Dz6QW1l1vUrt6Je976kB3HHxNT5fQf0ebipd/SjzJoi NNhnjezQEomzG2XpY1XTwerU6FqrcOZwXG1GAjgNrmuYrmKHOV/3XbTLnoIFd8LH5OX3 4XQUbwAM2eSiDYkWO5iN01CQMxnx2VZiKGTndvK2egAR7H9UrQDB4n+CQn/1T/AdZ8sO R+lg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=Z/+PShzHeuWeSQbVu69qWjybFwLZgWZYSy7GBE68WGo=; b=r1DyPBKt10Oz+Ff9Cpq8JB2nUZkHo4bplX8Wl1TXgLBUYhP7iTcagDQ14qV1W7fyya pkdCbvcOQ5J4uPyoaCFKQOytZkc/Xqzwkr5ImESU7KdSIpLWM6dotPKQdMC9fivWBhP0 Lhlhvv85+/cqp4ANXQZj5tSQgg1BXJg3GXGwx3+BReud1hchlqkEBh+/6hiolL1v6WBw cDXf3jP4wN+bwDAmhpUK2+9J5UH/JDUqOUsJyUyi6DElUTrD5AfW3L/Olro+vqrqHDU/ V6D3bgbb0ijekkaQDngH7qBsKiap3NiJtJJrcrcL377DJKlIDRdiOh2c5NTcvJNCgN/C hAEA== X-Gm-Message-State: AOAM531exPe9ILWgm0Kzz7S5UkXOBqItWlfne1DvhQn9iTfaUSmaODoa O051l/4Jsi0dXYuGzTiYbnmkLA== X-Received: by 2002:a50:cf4c:: with SMTP id d12mr21497773edk.115.1632725297968; Sun, 26 Sep 2021 23:48:17 -0700 (PDT) Received: from apalos.home ([2a02:587:4672:866:2e56:dcff:fe9a:8f06]) by smtp.gmail.com with ESMTPSA id dm8sm9948398edb.90.2021.09.26.23.48.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Sep 2021 23:48:17 -0700 (PDT) From: Ilias Apalodimas To: trini@konsulko.com Cc: mark.kettenis@xs4all.nl, Ilias Apalodimas , Bharat Gooty , Rayagonda Kokatanur , Rick Chen , Leo , Thomas Fitzsimmons , Simon Glass , Bin Meng , Green Wan , =?utf-8?q?Marek_Beh=C3=BAn?= , Sean Anderson , Lukas Auer , Brad Kim , Zong Li , Heinrich Schuchardt , Dimitri John Ledkov , David Abdurachmanov , u-boot@lists.denx.de Subject: [PATCH 3/3] treewide: Remove OF_PRIOR_STAGE Date: Mon, 27 Sep 2021 09:47:48 +0300 Message-Id: <20210927064751.78591-3-ilias.apalodimas@linaro.org> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20210927064751.78591-1-ilias.apalodimas@linaro.org> References: <20210927064751.78591-1-ilias.apalodimas@linaro.org> MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean The previous patches removed OF_PRIOR_STAGE from the last consumers of the Kconfig option. Cleanup any references to it in documentation, code and configuration options. Signed-off-by: Ilias Apalodimas --- dts/Kconfig | 11 ++--------- include/fdtdec.h | 4 ---- lib/fdtdec.c | 2 -- tools/binman/binman.rst | 16 ++++++---------- 4 files changed, 8 insertions(+), 25 deletions(-) -- 2.33.0 Reviewed-by: Simon Glass diff --git a/dts/Kconfig b/dts/Kconfig index 39270b47f9f0..100769017e12 100644 --- a/dts/Kconfig +++ b/dts/Kconfig @@ -22,7 +22,7 @@ config BINMAN config BINMAN_STANDALONE_FDT bool depends on BINMAN - default y if OF_BOARD || OF_PRIOR_STAGE + default y if OF_BOARD help This option tells U-Boot build system that a standalone device tree source is explicitly required when using binman to package U-Boot. @@ -32,7 +32,7 @@ config BINMAN_STANDALONE_FDT directory for a specific board. Such device tree sources are built for OF_SEPARATE or OF_EMBED. However for a scenario like the board device tree blob is not provided in the U-Boot build tree, but fed to U-Boot - in the runtime, e.g.: in the OF_PRIOR_STAGE case that it is passed by + in the runtime, e.g.: in the OF_BOARD case that it is passed by a prior stage bootloader. For such scenario, a standalone device tree blob containing binman node to describe how to package U-Boot should be provided explicitly. @@ -122,13 +122,6 @@ config OF_HOSTFILE This is only useful for Sandbox. Use the -d flag to U-Boot to specify the file to read. -config OF_PRIOR_STAGE - bool "Prior stage bootloader DTB for DT control" - help - If this option is enabled, the device tree used for DT - control will be read from a device tree binary, at a memory - location passed to U-Boot by the prior stage bootloader. - endchoice config DEFAULT_DEVICE_TREE diff --git a/include/fdtdec.h b/include/fdtdec.h index 8ac20c9a64f7..d0e13fc18313 100644 --- a/include/fdtdec.h +++ b/include/fdtdec.h @@ -55,10 +55,6 @@ struct bd_info; #define SPL_BUILD 0 #endif -#ifdef CONFIG_OF_PRIOR_STAGE -extern phys_addr_t prior_stage_fdt_address; -#endif - /* * Information about a resource. start is the first address of the resource * and end is the last address (inclusive). The length of the resource will diff --git a/lib/fdtdec.c b/lib/fdtdec.c index 7358cb6dd168..7b379564600d 100644 --- a/lib/fdtdec.c +++ b/lib/fdtdec.c @@ -1580,8 +1580,6 @@ int fdtdec_setup(void) puts("Failed to read control FDT\n"); return -1; } -# elif defined(CONFIG_OF_PRIOR_STAGE) - gd->fdt_blob = (void *)(uintptr_t)prior_stage_fdt_address; # endif # ifndef CONFIG_SPL_BUILD /* Allow the early environment to override the fdt address */ diff --git a/tools/binman/binman.rst b/tools/binman/binman.rst index 09e7b5719825..614df541c5ac 100644 --- a/tools/binman/binman.rst +++ b/tools/binman/binman.rst @@ -232,18 +232,18 @@ You can use other, more specific CONFIG options - see 'Automatic .dtsi inclusion' below. -Using binman with OF_BOARD or OF_PRIOR_STAGE +Using binman with OF_BOARD -------------------------------------------- Normally binman is used with a board configured with OF_SEPARATE or OF_EMBED. This is a typical scenario where a device tree source that contains the binman node is provided in the arch//dts directory for a specific board. -However for a board configured with OF_BOARD or OF_PRIOR_STAGE, no device tree -blob is provided in the U-Boot build phase hence the binman node information -is not available. In order to support such use case, a new Kconfig option -BINMAN_STANDALONE_FDT is introduced, to tell the build system that a standalone -device tree blob containing binman node is explicitly required. +However for a board configured with OF_BOARD, no device tree blob is provided +in the U-Boot build phase hence the binman node information is not available. +In order to support such use case, a new Kconfig option BINMAN_STANDALONE_FDT +is introduced, to tell the build system that a standalone device tree blob +containing binman node is explicitly required. Note there is a Kconfig option BINMAN_FDT which enables U-Boot run time to access information about binman entries, stored in the device tree in a binman @@ -252,10 +252,6 @@ For the other OF_CONTROL methods, it's quite possible binman node is not available as binman is invoked during the build phase, thus this option is not turned on by default for these OF_CONTROL methods. -See qemu-riscv64_spl_defconfig for an example of how binman is used with -OF_PRIOR_STAGE to generate u-boot.itb image. - - Access to binman entry offsets at run time (symbols) ----------------------------------------------------