From: Richard Henderson <richard.henderson@linaro.org>
To: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Cc: u-boot@lists.denx.de, trini@konsulko.com, cfsworks@gmail.com,
caleb.connolly@linaro.org, sumit.garg@linaro.org,
Ryan Chen <ryan_chen@aspeedtech.com>,
Chia-Wei Wang <chiawei_wang@aspeedtech.com>,
Aspeed BMC SW team <BMC-SW@aspeedtech.com>,
Joel Stanley <joel@jms.id.au>, Simon Glass <sjg@chromium.org>,
Philipp Tomsich <philipp.tomsich@vrull.eu>,
Kever Yang <kever.yang@rock-chips.com>,
Michal Simek <michal.simek@amd.com>,
Yegor Yefremov <yegorslists@googlemail.com>,
Heinrich Schuchardt <xypron.glpk@gmx.de>,
Shiji Yang <yangshiji66@outlook.com>,
Bin Meng <bmeng@tinylab.org>
Subject: Re: [PATCH v3 2/7] arm: clean up v7 and v8 linker scripts for bss_start/end
Date: Wed, 13 Mar 2024 12:43:29 -1000 [thread overview]
Message-ID: <2a58e815-acfa-4659-80f5-08d314497897@linaro.org> (raw)
In-Reply-To: <CAC_iWjKhM6Ono+C-t-3g=OSo=5wF8jAYzoZ-NUyNUt7MHTMy=w@mail.gmail.com>
On 3/13/24 11:43, Ilias Apalodimas wrote:
> Hi Richard,
>
> On Wed, 13 Mar 2024 at 22:19, Richard Henderson
> <richard.henderson@linaro.org> wrote:
>>
>> On 3/13/24 06:23, Ilias Apalodimas wrote:
>>> +++ b/arch/arm/cpu/armv8/u-boot-spl.lds
>>> @@ -63,18 +63,11 @@ SECTIONS
>>>
>>> _image_binary_end = .;
>>>
>>> - .bss_start (NOLOAD) : {
>>> - . = ALIGN(8);
>>> - KEEP(*(.__bss_start));
>>> - } >.sdram
>>> -
>>> - .bss (NOLOAD) : {
>>> + .bss : {
>>> + __bss_start = .;
>>> *(.bss*)
>>> - . = ALIGN(8);
>>> - } >.sdram
>>> -
>>> - .bss_end (NOLOAD) : {
>>> - KEEP(*(.__bss_end));
>>> + . = ALIGN(8);
>>> + __bss_end = .;
>>
>> Still missing the alignment on .bss, previously in .bss_start.
>
> Since this is emitted in .sdram memory I can't define it as
> .bss ALIGN(8) : {....} since the calculated memory will be outside the
> sdram-defined region
>
> I could define it as
> .bss : {
> . = ALIGN(8);
> __bss_start = .;
> ......
> }
>
> But instead, I added an assert at the bottom which will break the
> linking if the __bss_start is not 8byte aligned.
I think it would be clearer to assert on __bss_start address rather than
CONFIG_SPL_BSS_START_ADDR, if that's possible. If not, then the constant will have to do.
r~
next prev parent reply other threads:[~2024-03-13 22:51 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-03-13 16:23 [PATCH v3 0/7] Clean up arm linker scripts Ilias Apalodimas
2024-03-13 16:23 ` [PATCH v3 1/7] arm: baltos: remove custom linker script Ilias Apalodimas
2024-03-13 16:23 ` [PATCH v3 2/7] arm: clean up v7 and v8 linker scripts for bss_start/end Ilias Apalodimas
2024-03-13 20:19 ` Richard Henderson
2024-03-13 21:43 ` Ilias Apalodimas
2024-03-13 22:43 ` Richard Henderson [this message]
2024-03-14 7:59 ` Ilias Apalodimas
2024-03-13 22:57 ` Sam Edwards
2024-03-14 0:40 ` Tom Rini
2024-03-13 16:23 ` [PATCH v3 3/7] arm: fix __efi_runtime_rel_start/end definitions Ilias Apalodimas
2024-03-13 16:23 ` [PATCH v3 4/7] arm: clean up v7 and v8 linker scripts for __rel_dyn_start/end Ilias Apalodimas
2024-03-13 16:23 ` [PATCH v3 5/7] arm: fix __efi_runtime_start/end definitions Ilias Apalodimas
2024-03-13 16:23 ` [PATCH v3 6/7] arm: move image_copy_start/end to linker symbols Ilias Apalodimas
2024-03-13 16:23 ` [PATCH v3 7/7] arm: remove redundant section alignments Ilias Apalodimas
2024-03-13 20:21 ` Richard Henderson
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=2a58e815-acfa-4659-80f5-08d314497897@linaro.org \
--to=richard.henderson@linaro.org \
--cc=BMC-SW@aspeedtech.com \
--cc=bmeng@tinylab.org \
--cc=caleb.connolly@linaro.org \
--cc=cfsworks@gmail.com \
--cc=chiawei_wang@aspeedtech.com \
--cc=ilias.apalodimas@linaro.org \
--cc=joel@jms.id.au \
--cc=kever.yang@rock-chips.com \
--cc=michal.simek@amd.com \
--cc=philipp.tomsich@vrull.eu \
--cc=ryan_chen@aspeedtech.com \
--cc=sjg@chromium.org \
--cc=sumit.garg@linaro.org \
--cc=trini@konsulko.com \
--cc=u-boot@lists.denx.de \
--cc=xypron.glpk@gmx.de \
--cc=yangshiji66@outlook.com \
--cc=yegorslists@googlemail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.