From: Tom Rini <trini@konsulko.com>
To: Fabio Estevam <festevam@gmail.com>
Cc: Marek Vasut <marek.vasut@mailbox.org>,
Kever Yang <kever.yang@rock-chips.com>,
u-boot@lists.denx.de,
Marek Vasut <marek.vasut+renesas@mailbox.org>,
Beleswar Padhi <b-padhi@ti.com>,
"NXP i.MX U-Boot Team" <uboot-imx@nxp.com>,
Adam Ford <aford173@gmail.com>,
Andre Przywara <andre.przywara@arm.com>,
Aspeed BMC SW team <BMC-SW@aspeedtech.com>,
Chia-Wei Wang <chiawei_wang@aspeedtech.com>,
Eugen Hristev <eugen.hristev@linaro.org>,
Ilias Apalodimas <ilias.apalodimas@linaro.org>,
Jagan Teki <jagan@amarulasolutions.com>,
Joel Stanley <joel@jms.id.au>,
Michal Simek <michal.simek@amd.com>,
Philipp Tomsich <philipp.tomsich@vrull.eu>,
Richard Henderson <richard.henderson@linaro.org>,
Ryan Chen <ryan_chen@aspeedtech.com>,
Stefano Babic <sbabic@nabladev.com>
Subject: Re: [PATCH 02/10] arm: Update linker scripts to ensure appended device tree is aligned
Date: Thu, 22 Jan 2026 13:10:42 -0600 [thread overview]
Message-ID: <20260122191042.GD3416603@bill-the-cat> (raw)
In-Reply-To: <CAOMZO5AZiBajXK1b6Mse9LPwHEzhJSM_-OcQs4BsnbXP3WzuxA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 3311 bytes --]
On Thu, Jan 22, 2026 at 03:47:52PM -0300, Fabio Estevam wrote:
> Hi Tom and Marek,
>
> On Thu, Jan 22, 2026 at 11:23 AM Tom Rini <trini@konsulko.com> wrote:
>
> > We did that, yes. I'm not sure what Fabio is running in to here..
>
> Let me share more information with you.
>
> The board I am working on is based on Rockchip RV1103 (ARMv7) and will
> submit it upstream soon.
Can you please share it with my off-list maybe? I'm still confused as to
where the "sram" and "sdram" parts are coming from.
> The board was booting fin last week. Yesterday, after rebasing it
> against the top of the tree U-Boot, the board no longer boots.
>
> The boot error is:
>
> Missing DTB
> spl_early_init() failed: -2
> ### ERROR ### Please RESET the board ###
>
> After running "git bisect", I found Tom's commit 8b0ebe054bb3 ("arm:
> Update linker scripts to ensure appended device tree is aligned") to
> be the guilty one.
>
> If I partially revert the arm/cpu/u-boot-spl.lds change, as shown
> below, the board boots again:
>
> --- a/arch/arm/cpu/u-boot-spl.lds
> +++ b/arch/arm/cpu/u-boot-spl.lds
> @@ -51,9 +51,9 @@ SECTIONS
> __rel_dyn_start = .;
> *(.rel*)
> __rel_dyn_end = .;
> - . = ALIGN(8);
> }
>
> + . = ALIGN(8);
> _image_binary_end = .;
> _end = .;
>
> With Tom's commit applied (failing case), the spl/u-boot-spl.map looks
> like this:
>
> .rel.dyn 0x0000000000015cac 0x4
> 0x0000000000015cac __rel_dyn_start = .
> *(.rel*)
> .rel.iplt 0x0000000000015cac 0x0 arch/arm/cpu/armv7/start.o
> 0x0000000000015cac __rel_dyn_end = .
> 0x0000000000015cb0 . = ALIGN (0x8)
> *fill* 0x0000000000015cac 0x4
> 0x0000000000015cb0 _image_binary_end = .
> 0x0000000000015cb0 _end = .
>
> With the partial revert above (booting case):
>
> .rel.dyn 0x0000000000015cac 0x0
> 0x0000000000015cac __rel_dyn_start = .
> *(.rel*)
> .rel.iplt 0x0000000000015cac 0x0 arch/arm/cpu/armv7/start.o
> 0x0000000000015cac __rel_dyn_end = .
> 0x0000000000015cb0 . = ALIGN (0x8)
> 0x0000000000015cb0 _image_binary_end = .
> 0x0000000000015cb0 _end = .
>
> Basically, in the good case, .rel.dyn is zero. In the failing case:
> .rel.dyn is 0x4 and *fill* is 0x4 as well.
>
> This change messes with dtb being found in SPL.
>
> What would be a proper fix?
Well, where is the dtb ending up in the resulting binary? The addresses
are aligned correctly, but the dtb isn't where it's supposed to be,
where is it instead? A challenge here is that I could only check the
linker script used by about half of the 32bit ARM boards
(arch/arm/mach-omap2/u-boot-spl.lds) and not the one used by the other
half (arch/arm/cpu/u-boot-spl.lds). The initial error you reported makes
me wonder if we can somehow unify these two afterall, which would be
good in general to do.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2026-01-22 19:10 UTC|newest]
Thread overview: 56+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-15 22:19 [PATCH 00/10] Update linker scripts to ensure appended device tree is correctly aligned Tom Rini
2026-01-15 22:19 ` [PATCH 01/10] Makefile: Have binary_size_check report only first match of _image_binary_end Tom Rini
2026-01-22 9:07 ` Marek Vasut
2026-01-22 14:21 ` Tom Rini
2026-01-15 22:19 ` [PATCH 02/10] arm: Update linker scripts to ensure appended device tree is aligned Tom Rini
2026-01-16 9:59 ` Ilias Apalodimas
2026-01-16 14:40 ` Tom Rini
2026-01-20 8:38 ` Ilias Apalodimas
2026-01-20 14:27 ` Tom Rini
2026-01-16 10:00 ` Michal Simek
2026-01-22 3:08 ` Fabio Estevam
2026-01-22 3:33 ` Fabio Estevam
2026-01-22 11:22 ` Marek Vasut
2026-01-22 14:23 ` Tom Rini
2026-01-22 18:47 ` Fabio Estevam
2026-01-22 19:10 ` Tom Rini [this message]
2026-01-22 19:19 ` Fabio Estevam
2026-01-22 19:28 ` Tom Rini
2026-01-22 19:32 ` Fabio Estevam
2026-01-22 19:42 ` Tom Rini
2026-01-22 22:56 ` Fabio Estevam
2026-01-22 23:24 ` Tom Rini
2026-01-23 0:25 ` Fabio Estevam
2026-01-23 0:52 ` Fabio Estevam
2026-01-23 14:27 ` Tom Rini
2026-01-23 15:45 ` Fabio Estevam
2026-01-23 15:50 ` Tom Rini
2026-01-22 14:25 ` Tom Rini
2026-02-04 21:16 ` Phil Sutter
2026-02-04 21:20 ` Tom Rini
2026-02-04 21:27 ` Phil Sutter
2026-02-04 21:31 ` Tom Rini
2026-02-04 21:40 ` Phil Sutter
2026-02-04 21:50 ` Tom Rini
2026-02-04 23:00 ` Phil Sutter
2026-02-04 23:04 ` Tom Rini
2026-02-04 23:29 ` Phil Sutter
2026-02-04 23:35 ` Tom Rini
2026-02-04 23:48 ` Phil Sutter
2026-02-05 18:01 ` Tom Rini
2026-01-15 22:19 ` [PATCH 03/10] m68k: " Tom Rini
2026-01-15 22:19 ` [PATCH 04/10] microblaze: " Tom Rini
2026-01-16 9:59 ` Michal Simek
2026-01-16 10:00 ` Ilias Apalodimas
2026-01-15 22:19 ` [PATCH 05/10] mips: " Tom Rini
2026-01-20 13:57 ` Daniel Schwierzeck
2026-01-15 22:19 ` [PATCH 06/10] nios2: " Tom Rini
2026-01-16 10:00 ` Ilias Apalodimas
2026-01-15 22:19 ` [PATCH 07/10] powerpc: " Tom Rini
2026-02-06 7:18 ` Christophe Leroy (CS GROUP)
2026-01-15 22:19 ` [PATCH 08/10] riscv: " Tom Rini
2026-01-16 1:27 ` Leo Liang
2026-01-16 9:49 ` Ilias Apalodimas
2026-01-15 22:19 ` [PATCH 09/10] sandbox: " Tom Rini
2026-01-15 22:19 ` [PATCH 10/10] x86: " Tom Rini
2026-01-20 18:08 ` [PATCH 00/10] Update linker scripts to ensure appended device tree is correctly aligned Tom Rini
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260122191042.GD3416603@bill-the-cat \
--to=trini@konsulko.com \
--cc=BMC-SW@aspeedtech.com \
--cc=aford173@gmail.com \
--cc=andre.przywara@arm.com \
--cc=b-padhi@ti.com \
--cc=chiawei_wang@aspeedtech.com \
--cc=eugen.hristev@linaro.org \
--cc=festevam@gmail.com \
--cc=ilias.apalodimas@linaro.org \
--cc=jagan@amarulasolutions.com \
--cc=joel@jms.id.au \
--cc=kever.yang@rock-chips.com \
--cc=marek.vasut+renesas@mailbox.org \
--cc=marek.vasut@mailbox.org \
--cc=michal.simek@amd.com \
--cc=philipp.tomsich@vrull.eu \
--cc=richard.henderson@linaro.org \
--cc=ryan_chen@aspeedtech.com \
--cc=sbabic@nabladev.com \
--cc=u-boot@lists.denx.de \
--cc=uboot-imx@nxp.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox