From: Mattijs Korpershoek <mkorpershoek@baylibre.com>
To: Simon Glass <sjg@chromium.org>,
U-Boot Mailing List <u-boot@lists.denx.de>
Cc: Tom Rini <trini@konsulko.com>, Simon Glass <sjg@chromium.org>,
Eddie James <eajames@linux.ibm.com>,
Ilias Apalodimas <ilias.apalodimas@linaro.org>,
Safae Ouajih <souajih@baylibre.com>
Subject: Re: [PATCH v2 11/21] bootm: Move do_bootm_states() comment to header file
Date: Fri, 15 Dec 2023 13:02:38 +0100 [thread overview]
Message-ID: <87il4zu10h.fsf@baylibre.com> (raw)
In-Reply-To: <20231214165112.2182274-7-sjg@chromium.org>
Hi Simon,
Thank you for the patch.
On jeu., déc. 14, 2023 at 09:50, Simon Glass <sjg@chromium.org> wrote:
> This is an exported function, so move the function comment to the
> bootm.h header file.
>
> Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
> ---
>
> Changes in v2:
> - Split out patch to move do_bootm_states() comment to header
>
> boot/bootm.c | 25 -------------------------
> include/bootm.h | 25 +++++++++++++++++++++++++
> 2 files changed, 25 insertions(+), 25 deletions(-)
>
> diff --git a/boot/bootm.c b/boot/bootm.c
> index 9e42fa5117d0..875f8a1c2a56 100644
> --- a/boot/bootm.c
> +++ b/boot/bootm.c
> @@ -990,31 +990,6 @@ unmap_image:
> return ret;
> }
>
> -/**
> - * Execute selected states of the bootm command.
> - *
> - * Note the arguments to this state must be the first argument, Any 'bootm'
> - * or sub-command arguments must have already been taken.
> - *
> - * Note that if states contains more than one flag it MUST contain
> - * BOOTM_STATE_START, since this handles and consumes the command line args.
> - *
> - * Also note that aside from boot_os_fn functions and bootm_load_os no other
> - * functions we store the return value of in 'ret' may use a negative return
> - * value, without special handling.
> - *
> - * @param cmdtp Pointer to bootm command table entry
> - * @param flag Command flags (CMD_FLAG_...)
> - * @param argc Number of subcommand arguments (0 = no arguments)
> - * @param argv Arguments
> - * @param states Mask containing states to run (BOOTM_STATE_...)
> - * @param images Image header information
> - * @param boot_progress 1 to show boot progress, 0 to not do this
> - * Return: 0 if ok, something else on error. Some errors will cause this
> - * function to perform a reboot! If states contains BOOTM_STATE_OS_GO
> - * then the intent is to boot an OS, so this function will not return
> - * unless the image type is standalone.
> - */
> int do_bootm_states(struct cmd_tbl *cmdtp, int flag, int argc,
> char *const argv[], int states, struct bootm_headers *images,
> int boot_progress)
> diff --git a/include/bootm.h b/include/bootm.h
> index c9ab55f18d39..950ce5181f1d 100644
> --- a/include/bootm.h
> +++ b/include/bootm.h
> @@ -131,6 +131,31 @@ int bootm_find_images(ulong img_addr, const char *conf_ramdisk,
> */
> int bootm_measure(struct bootm_headers *images);
>
> +/**
> + * Execute selected states of the bootm command.
> + *
> + * Note the arguments to this state must be the first argument, Any 'bootm'
> + * or sub-command arguments must have already been taken.
> + *
> + * Note that if states contains more than one flag it MUST contain
> + * BOOTM_STATE_START, since this handles and consumes the command line args.
> + *
> + * Also note that aside from boot_os_fn functions and bootm_load_os no other
> + * functions we store the return value of in 'ret' may use a negative return
> + * value, without special handling.
> + *
> + * @param cmdtp Pointer to bootm command table entry
> + * @param flag Command flags (CMD_FLAG_...)
> + * @param argc Number of subcommand arguments (0 = no arguments)
> + * @param argv Arguments
> + * @param states Mask containing states to run (BOOTM_STATE_...)
> + * @param images Image header information
> + * @param boot_progress 1 to show boot progress, 0 to not do this
> + * Return: 0 if ok, something else on error. Some errors will cause this
> + * function to perform a reboot! If states contains BOOTM_STATE_OS_GO
> + * then the intent is to boot an OS, so this function will not return
> + * unless the image type is standalone.
> + */
> int do_bootm_states(struct cmd_tbl *cmdtp, int flag, int argc,
> char *const argv[], int states, struct bootm_headers *images,
> int boot_progress);
> --
> 2.43.0.472.g3155946c3a-goog
next prev parent reply other threads:[~2023-12-15 12:02 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-14 16:50 [PATCH v2 00/21] Complete decoupling of bootm logic from commands Simon Glass
2023-12-14 16:50 ` [PATCH v2 01/21] mips: Add a reset_cpu() function Simon Glass
2023-12-14 16:50 ` [PATCH v2 02/21] m68k: " Simon Glass
2023-12-14 16:50 ` [PATCH v2 03/21] ppc: " Simon Glass
2023-12-14 16:50 ` [PATCH v2 04/21] nios2: " Simon Glass
2023-12-14 16:50 ` [PATCH v2 05/21] riscv: " Simon Glass
2023-12-15 6:38 ` Chanho Park
2023-12-14 16:50 ` [PATCH v2 06/21] bootm: Adjust how the board is reset Simon Glass
2023-12-15 12:01 ` Mattijs Korpershoek
2023-12-14 16:50 ` [PATCH v2 07/21] sandbox: bootm: Enable more bootm OS methods Simon Glass
2023-12-14 16:50 ` [PATCH v2 08/21] bootm: Create a struct for argument information Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 09/21] bootm: Adjust arguments of boot_os_fn Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 10/21] bootm: Add more fields to bootm_info Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 11/21] bootm: Move do_bootm_states() comment to header file Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-15 12:02 ` Mattijs Korpershoek [this message]
2023-12-14 16:50 ` [PATCH v2 12/21] booti: Avoid use of #ifdef Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 13/21] bootz: " Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 14/21] bootm: Drop arguments from do_bootm_states() Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 15/21] bootm: Rename do_bootm_states() to bootm_run_states() Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 16/21] bootm: Tidy up boot_selected_os() Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 17/21] bootm: Create a function to run through the bootm states Simon Glass
2023-12-14 17:51 ` Tom Rini
2023-12-14 16:50 ` [PATCH v2 18/21] stm32: Use local vars in stm32prog for initrd and fdt Simon Glass
2023-12-15 11:55 ` Patrick DELAUNAY
2023-12-14 16:50 ` [PATCH v2 19/21] bootm: Create a function to run through the bootz states Simon Glass
2023-12-14 16:50 ` [PATCH v2 20/21] stm32: Use bootm_run() and bootz_run() Simon Glass
2023-12-15 11:57 ` Patrick DELAUNAY
2023-12-14 16:50 ` [PATCH v2 21/21] bootm: Create a function to run through the booti states Simon Glass
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=87il4zu10h.fsf@baylibre.com \
--to=mkorpershoek@baylibre.com \
--cc=eajames@linux.ibm.com \
--cc=ilias.apalodimas@linaro.org \
--cc=sjg@chromium.org \
--cc=souajih@baylibre.com \
--cc=trini@konsulko.com \
--cc=u-boot@lists.denx.de \
/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