From: Tom Rini <trini@konsulko.com>
To: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Cc: Quentin Schulz <quentin.schulz@cherry.de>,
richard.henderson@linaro.org, casey.connolly@linaro.org,
u-boot@lists.u-boot-project.org
Subject: Re: [PATCH 1/2] arm64: relocate: convert relocate_code to C
Date: Fri, 27 Nov 2026 12:35:15 -0600 [thread overview]
Message-ID: <20261127183515.GO3176972@bill-the-cat> (raw)
In-Reply-To: <CAC_iWjKfbu1JTCeWDwOG36DkvCTdc0hE_YFWKDgkdhSCmsWZHA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1468 bytes --]
On Wed, Nov 25, 2026 at 07:11:13PM +0200, Ilias Apalodimas wrote:
> On Wed, 25 Nov 2026 at 19:07, Quentin Schulz <quentin.schulz@cherry.de> wrote:
> >
> > Hi Ilias,
> >
> > On 11/25/26 8:41 AM, Ilias Apalodimas wrote:
> > > relocate_code() on arm64 is called from _main with sp and gd already
> > > pointing at the relocated area and lr pointing to the relocated copy of
> > > relocation_return. By that time pie_fixup has already run, if
> > > POSITION_INDEPENDENT is enabled, the image is fixed up and plain C works
> > > fine, like the rest of board_init_f(). So let's convert it to C which is
> > > much easier to read and maintain.
> > >
> > > While at it change the behaviour and order of cache maintenance.
> > > Invalidate the I-cache after the D-cache clean instead of before
> > > and add a 'dsb' between 'ic iallu' and the 'isb', which is the
> > > architecturally required sequence.
> > >
> >
> > suggestion: can you please make those separate commits?
> >
> > That should help us if we ever need to bisect this change. If it was
> > only in the conversion from ASM to C, or if it's related to the cache
> > changes?
>
> Yea I don't mind. But given that the older version was wrong and this
> is the sequence defined by the architecture, I was aiming to have it
> correct from the original commit.
>
> Tom any preference?
I think Quentin's point is valid, and correcting the order in C,
afterwards, is easy.
--
Tom
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
next prev parent reply other threads:[~2026-11-27 18:35 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-25 7:41 [PATCH 1/2] arm64: relocate: convert relocate_code to C Ilias Apalodimas
2026-11-25 7:41 ` [PATCH 2/2] arm64: Add RELR relocs Ilias Apalodimas
2026-11-25 17:20 ` Quentin Schulz
2026-11-26 12:48 ` Peter Robinson
2026-11-26 15:14 ` Ilias Apalodimas
2026-11-27 18:46 ` Tom Rini
2026-12-03 22:27 ` Ilias Apalodimas
2026-12-03 22:42 ` Tom Rini
2026-12-03 22:53 ` Ilias Apalodimas
2026-12-03 23:02 ` Tom Rini
2026-12-04 6:44 ` Ilias Apalodimas
2026-12-04 15:12 ` Tom Rini
2026-12-04 15:50 ` Ilias Apalodimas
2026-12-04 16:13 ` Ilias Apalodimas
2026-11-26 16:35 ` Richard Henderson
2026-11-26 16:58 ` Ilias Apalodimas
2026-11-26 20:51 ` Ilias Apalodimas
2026-12-03 22:14 ` Richard Henderson
2026-11-25 17:07 ` [PATCH 1/2] arm64: relocate: convert relocate_code to C Quentin Schulz
2026-11-25 17:08 ` Casey Connolly
2026-11-25 17:11 ` Ilias Apalodimas
2026-11-27 18:35 ` Tom Rini [this message]
2026-11-26 16:11 ` Richard Henderson
2026-11-26 16:18 ` Ilias Apalodimas
2026-11-26 17:03 ` Ilias Apalodimas
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=20261127183515.GO3176972@bill-the-cat \
--to=trini@konsulko.com \
--cc=casey.connolly@linaro.org \
--cc=ilias.apalodimas@linaro.org \
--cc=quentin.schulz@cherry.de \
--cc=richard.henderson@linaro.org \
--cc=u-boot@lists.u-boot-project.org \
/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.