public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Tom Rini <trini@konsulko.com>
To: Simon Glass <sjg@chromium.org>
Cc: u-boot@lists.denx.de, James Hilliard <james.hilliard1@gmail.com>,
	Jonas Karlman <jonas@kwiboo.se>,
	Marek Vasut <marek.vasut+renesas@mailbox.org>,
	Mayuresh Chitale <mchitale@ventanamicro.com>,
	Neil Armstrong <neil.armstrong@linaro.org>,
	Quentin Schulz <quentin.schulz@cherry.de>,
	Shiji Yang <yangshiji66@outlook.com>,
	Wolfgang Wallner <wolfgang.wallner@at.abb.com>
Subject: Re: [PATCH 00/13] boot: Make fit_image_load() easier to maintain
Date: Wed, 8 Apr 2026 10:26:16 -0600	[thread overview]
Message-ID: <20260408162616.GI41863@bill-the-cat> (raw)
In-Reply-To: <20260325165431.1027591-1-sjg@chromium.org>

[-- Attachment #1: Type: text/plain, Size: 2067 bytes --]

On Wed, Mar 25, 2026 at 10:54:09AM -0600, Simon Glass wrote:

> Before fit_image_load() was created, the code to load kernels, ramdisks
> and devicetrees from a FIT was spread around many functions. By
> combining most of the code in one place, it became possible to add more
> features in a consistent way. The 'loadables' feature was much easier to
> plumb in, for example.
> 
> While fit_image_load() was a substantial advance, it has never been a
> svelte function and the passing years have not been entirely kind. With
> a few new features on the horizon, this is a good time to improve the
> implementation.
> 
> This series splits much of the code from fit_image_load() into a number
> of smaller functions. Most of the changes are fairly mechanical, with
> just a few renames and tweaks here and there.
> 
> This should make the function much easier to maintain. It may also
> encourage someone to take a look at its callers, which could also use
> some attention.
> 
> Code-size impact: about +8 bytes on aarch64 and +24-40 bytes on arm, due
> to the compiler's register allocation across the new helper functions.
> 
> 
> Simon Glass (13):
>   boot: Split out the first part of fit_image_load()
>   boot: Move call to fit_image_select() and rename it
>   boot: Tidy up setting of the OS arch on host builds
>   boot: Move type and OS checking into a new function
>   boot: Move handling of the load_op into a separate function
>   boot: Move obtaining data from a FIT image into a function
>   boot: Check the image is allowed before setting os.arch
>   boot: Move the architecture check into check_allowed()
>   boot: Move image-decompression into a separate function
>   boot: Move decomp_image() into handle_load_op()
>   boot: Move setting the OS arch into check_allowed()
>   boot: Drop unnecessary data variable
>   boot: Tidy local variables in fit_image_load()

I've reviewed through 5, and I assume 6-13 have similar issues as the
rest. Please think about that before submitting a v2, thanks.

-- 
Tom

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

      parent reply	other threads:[~2026-04-08 16:26 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-03-25 16:54 [PATCH 00/13] boot: Make fit_image_load() easier to maintain Simon Glass
2026-03-25 16:54 ` [PATCH 01/13] boot: Split out the first part of fit_image_load() Simon Glass
2026-04-08 16:25   ` Tom Rini
2026-03-25 16:54 ` [PATCH 02/13] boot: Move call to fit_image_select() and rename it Simon Glass
2026-04-08 16:25   ` Tom Rini
2026-03-25 16:54 ` [PATCH 03/13] boot: Tidy up setting of the OS arch on host builds Simon Glass
2026-04-08 16:25   ` Tom Rini
2026-03-25 16:54 ` [PATCH 04/13] boot: Move type and OS checking into a new function Simon Glass
2026-04-08 16:26   ` Tom Rini
2026-03-25 16:54 ` [PATCH 05/13] boot: Move handling of the load_op into a separate function Simon Glass
2026-04-08 16:26   ` Tom Rini
2026-03-25 16:54 ` [PATCH 06/13] boot: Move obtaining data from a FIT image into a function Simon Glass
2026-03-25 16:54 ` [PATCH 07/13] boot: Check the image is allowed before setting os.arch Simon Glass
2026-03-25 16:54 ` [PATCH 08/13] boot: Move the architecture check into check_allowed() Simon Glass
2026-03-25 16:54 ` [PATCH 09/13] boot: Move image-decompression into a separate function Simon Glass
2026-03-25 16:54 ` [PATCH 10/13] boot: Move decomp_image() into handle_load_op() Simon Glass
2026-03-25 16:54 ` [PATCH 11/13] boot: Move setting the OS arch into check_allowed() Simon Glass
2026-03-25 16:54 ` [PATCH 12/13] boot: Drop unnecessary data variable Simon Glass
2026-03-25 16:54 ` [PATCH 13/13] boot: Tidy local variables in fit_image_load() Simon Glass
2026-04-08 16:26 ` Tom Rini [this message]

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=20260408162616.GI41863@bill-the-cat \
    --to=trini@konsulko.com \
    --cc=james.hilliard1@gmail.com \
    --cc=jonas@kwiboo.se \
    --cc=marek.vasut+renesas@mailbox.org \
    --cc=mchitale@ventanamicro.com \
    --cc=neil.armstrong@linaro.org \
    --cc=quentin.schulz@cherry.de \
    --cc=sjg@chromium.org \
    --cc=u-boot@lists.denx.de \
    --cc=wolfgang.wallner@at.abb.com \
    --cc=yangshiji66@outlook.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