Commit Graph

96654 Commits

Author SHA1 Message Date
Matthew Garrett
652a64a686 Add command to set an environment variable to an EFI variable
We may want to make things conditional on EFI variable state

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-08 07:44:33 -07:00
Janis Danisevskis
de05434022 Fix efi_bind_block.
efi_bind_block had two issues.
1. A pointer to a the stack was inserted as plat structure and thus used
beyond its life time.
2. Only the first segment of the device path was copied into the
platfom data structure resulting in an unterminated device path.

Signed-off-by: Janis Danisevskis <jdanisevskis@aurora.tech>
Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-08 07:44:33 -07:00
Matthew Garrett
cad355ebe0 Use the correct ramdisk address
CONFIG_SYS_BOOT_RAMDISK_HIGH copies the initrd out of the FIT and into
correctly aligned RAM, but the addresses used for this are then discarded
by the x86 bootm code. Fix that.

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-08 07:44:33 -07:00
Matthew Garrett
2e7bf25f6b Support separate DTB files with the UEFI app
The UEFI app is an actual executable with things like section headers,
so just gluing the DTB onto the end of it won't work. Add an additional
section to contain this and allocate some space, and then during build
copy the DTB into that section.

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-08 07:44:33 -07:00
Matthew Garrett
f07b9497ba Add UEFI TPM2 driver
Add support for driving a TPM via UEFI firmware provided drivers, and
bind those devices from the UEFI app.

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-08 07:44:33 -07:00
Matthew Garrett
4bb984a205 Add EFI network driver
Add a driver that makes use of the UEFI Simple Network Protocol to
support network access when using the UEFI app implementation, and hook
up the app code to instantiate it for probed devices.

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
Add include of linux/ctype in epautoconf.c and conditional net.h:
Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-08 07:44:21 -07:00
Matthew Garrett
d4aa4b64d4 Hook up EFI env variable support in the EFI app
Add simple support for accessing EFI variables when in EFI app mode

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-07 17:53:09 -07:00
Matthew Garrett
dcca74b0d5 Add a command to find a load address
For systems with more complicated firmware, the firmware memory map may
vary significantly based on a number of factors. This makes it difficult to
pick a hardcoded load address. Add a command for finding an available
address with sufficient room to load the provided path.

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-07 17:53:09 -07:00
Matthew Garrett
e17915d63c Add part_find command
part_find takes a GPT GUID and searches for a partition that matches
that. It then sets the target_part environment variable to the media
type, device number and partition number that matched, allowing
$target_part to be passed directly to bootm and similar commands.

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-07 17:53:09 -07:00
Matthew Garrett
9121737455 Add EFI handover support to bootm
We want to jump into the EFI stub in the kernel so it can perform
appropriate init and call ExitBootServices. Add support for doing that,
including ensuring that we copy the kernel to somewhere that's not
currently being used by the firmware.

Signed-off-by: Matthew Garrett <mgarrett@aurora.tech>
Reviewed-by: Simon Glass <sjg@chromium.org>
Drop use of image_info_t:
Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-07 17:52:59 -07:00
Simon Glass
6972edf855 Merge branch 'ci' into 'master'
video: test: Split copy frame buffer check into a function

See merge request u-boot/u-boot!9
2024-12-07 23:37:39 +00:00
Simon Glass
cee7f69038 scripts: Add a script for building and booting QEMU
It is handy to be able to quickly build and boot a QEMU image for a
particular architecture and distro.

Add a script for this purpose. It supports only arm and x86 at present.
For distros it only supports Ubuntu. Both 32- and 64-bit builds are
supported.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-07 15:55:33 -07:00
Alexander Graf
b557c73feb video: Enable VIDEO_DAMAGE for drivers that need it
Some drivers call video_set_flush_dcache() to indicate that they want to
have the dcache flushed for the frame buffer. These drivers benefit from
our new video damage control, because we can reduce the amount of memory
that gets flushed significantly.

This patch enables video damage control for all device drivers that call
video_set_flush_dcache() to make sure they benefit from it.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
[Alper: Add to VIDEO_TIDSS, imply instead of select]
Co-developed-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-14-alpernebiyasak@gmail.com/
2024-12-07 15:55:33 -07:00
Alexander Graf
8dbdb3883c video: Always compile cache flushing code
The dcache flushing code path was conditional on ARM && !DCACHE config
options. However, dcaches exist on other platforms as well and may need
clearing if their driver requires it.

Simplify the compile logic and always enable the dcache flush logic in
the video core. That way, drivers can always rely on it to call the arch
specific callbacks.

This will increase code size for non-ARM platforms with CONFIG_VIDEO=y
slightly.

Reported-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Signed-off-by: Alexander Graf <agraf@csgraf.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-13-alpernebiyasak@gmail.com/
Added workaround for CONFIG_SYS_CACHELINE_SIZE for ibex-ast2700:
Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-07 15:55:33 -07:00
Alexander Graf
abbc0861a1 video: Use VIDEO_DAMAGE for VIDEO_COPY
CONFIG_VIDEO_COPY implemented a range-based copying mechanism: If we
print a single character, it will always copy the full range of bytes
from the top left corner of the character to the lower right onto the
uncached frame buffer. This includes pretty much the full line contents
of the printed character.

Since we now have proper damage tracking, let's make use of that to reduce
the amount of data we need to copy. With this patch applied, we will only
copy the tiny rectangle surrounding characters when we print them,
speeding up the video console.

After this, changes to the main frame buffer are not immediately copied
to the copy frame buffer, but postponed until the next video device
sync. So issue an explicit sync before inspecting the copy frame buffer
contents for the video tests.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
[Alper: Rebase for fontdata->height/w, fill_part(), fix memmove(dev),
        drop from defconfig, use damage.xstart/yend, use IS_ENABLED(),
        call video_sync() before copy_fb check, update video_copy test]
Co-developed-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-12-alpernebiyasak@gmail.com/
2024-12-07 15:55:33 -07:00
Alexander Graf
5790296c9a video: Only dcache flush damaged lines
Now that we have a damage area tells us which parts of the frame buffer
actually need updating, let's only dcache flush those on video_sync()
calls. With this optimization in place, frame buffer updates - especially
on large screen such as 4k displays - speed up significantly.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
Reported-by: Da Xue <da@libre.computer>
[Alper: Use damage.xstart/yend, IS_ENABLED()]
Co-developed-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-11-alpernebiyasak@gmail.com/
2024-12-07 15:55:33 -07:00
Alexander Graf
a4f1afb5a8 efi_loader: GOP: Add damage notification on BLT
Now that we have a damage tracking API, let's populate damage done by
UEFI payloads when they BLT data onto the screen.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
Reported-by: Da Xue <da@libre.computer>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
[Alper: Add struct comment for new member]
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-10-alpernebiyasak@gmail.com/
2024-12-07 15:55:33 -07:00
Alexander Graf
b10aa18edb video: Add damage notification on bmp display
Let's report the video damage when we draw a bitmap on the screen. This
way we can later lazily flush only relevant regions to hardware.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
Reported-by: Da Xue <da@libre.computer>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-9-alpernebiyasak@gmail.com/
2024-12-07 15:55:33 -07:00
Alper Nebi Yasak
a3e98af3e1 video: test: Test video damage tracking via vidconsole
With VIDEO_DAMAGE, the video uclass tracks updated regions of the frame
buffer in order to avoid unnecessary work during a video sync. Enable
the config in sandbox and add a test for it, by printing strings at a
few locations and checking the tracked region.

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Adjust test avoid temporary failures in this patch:
Signed-off-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-8-alpernebiyasak@gmail.com/
2024-12-07 15:55:30 -07:00
Alexander Graf
cb238e7043 vidconsole: Add damage notifications to all vidconsole drivers
Now that we have a damage tracking API, let's populate damage done by
vidconsole drivers. We try to declare as little memory as damaged as
possible.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
Reported-by: Da Xue <da@libre.computer>
[Alper: Rebase for met->baseline, fontdata->height/width, make rotated
        console_putc_xy() damages pass tests, edit patch message]
Co-developed-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-7-alpernebiyasak@gmail.com/
2024-12-07 14:53:56 -07:00
Alexander Graf
04db90d39e dm: video: Add damage notification on display fills
Let's report the video damage when we fill parts of the screen. This
way we can later lazily flush only relevant regions to hardware.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
Reported-by: Da Xue <da@libre.computer>
[Alper: Move from video_clear() to video_fill(), video_fill_part()]
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-6-alpernebiyasak@gmail.com/
2024-12-07 14:53:56 -07:00
Alexander Graf
0780213413 dm: video: Add damage tracking API
We are going to introduce image damage tracking to fasten up screen
refresh on large displays. This patch adds damage tracking for up to
one rectangle of the screen which is typically enough to hold blt or
text print updates. Callers into this API and a reduced dcache flush
code path will follow in later patches.

Signed-off-by: Alexander Graf <agraf@csgraf.de>
Reported-by: Da Xue <da@libre.computer>
[Alper: Use xstart/yend, document new fields, return void from
        video_damage(), declare priv, drop headers, use IS_ENABLED()]
Co-developed-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-5-alpernebiyasak@gmail.com/
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-07 14:53:56 -07:00
Alper Nebi Yasak
944a637126 video: test: Test partial updates of hardware frame buffer
With VIDEO_COPY enabled, only the modified parts of the frame buffer are
intended to be copied to the hardware. Add a test that checks this, by
overwriting contents we prepared without telling the video uclass and
then checking if the overwritten contents have been redrawn on the next
sync.

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-4-alpernebiyasak@gmail.com/
2024-12-07 14:53:55 -07:00
Alper Nebi Yasak
916b9b68fd video: test: Support checking copy frame buffer contents
The video tests have a helper function to generate a pseudo-digest of
frame buffer contents, but it only does so for the main one. There is
another check that the copy frame buffer is the same as that. But
neither is enough to test if only the modified regions are copied to the
copy frame buffer, since we will want the two to be different in very
specific ways.

Add a boolean argument to the existing helper function to indicate which
frame buffer we want to inspect, and update the existing callers.

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-3-alpernebiyasak@gmail.com/
2024-12-07 14:53:01 -07:00
Alper Nebi Yasak
8c9a49261f video: test: Split copy frame buffer check into a function
While checking frame buffer contents, the video tests also check if the
copy frame buffer contents match the main frame buffer. To test if only
the modified regions are updated after a sync, we will need to create
situations where the two are mismatched. Split this check into another
function that we can skip calling, since we won't want it to error on
those mismatched cases.

Signed-off-by: Alper Nebi Yasak <alpernebiyasak@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Link: https://lore.kernel.org/u-boot/20230821135111.3558478-2-alpernebiyasak@gmail.com/
2024-12-07 14:53:01 -07:00
Simon Glass
00befd910a Merge branch 'lab' into 'master'
Revert "global_data: Drop spl_handoff"

See merge request u-boot/u-boot!8
2024-12-05 22:31:44 +00:00
Simon Glass
b753ce57a6 binman: Avoid skipping binman_init()
A recent lwip change stopped binman's init from working, so it is not
possible to read nodes from the image description anymore.

Correct this by dropping the offending line.

Signed-off-by: Simon Glass <sjg@chromium.org>
Fixes: 4d4d783812 net: lwip: add TFTP support and tftpboot command
2024-12-05 14:40:31 -07:00
Simon Glass
a873fec25b Revert "global_data: Drop spl_handoff"
This breaks chromebook_coral which says:

   Video: No video mode configured in FSP!

This reverts commit 2e9313179a.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 14:40:31 -07:00
Simon Glass
4189da1da1 Merge branch 'stda' into 'master'
bootstd: sunxi: Migrate to standard boot

See merge request u-boot/u-boot!7
2024-12-05 21:40:14 +00:00
Simon Glass
dadcfcb889 sunxi: Move to text environment
Convert these boards to use a text environment.

For the boards check, the only differences are extra spaces after the
semicolons in 'dfu_alt_info_ram' and 'partitions', both of which are
permitted.

Add in the special boot command for old kernels, dropping the
unnecessary and confusing hex prefixes.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 13:58:19 -07:00
Simon Glass
6cc483bc22 env: Provide a work-around for unquoting fdtfile
Some boards use a CONFIG option to specify the value of this variable.
This is normally handled by efi_get_distro_fdt_name() but in the case
of sunxi this does not work, since 'soc' is sunxi, but the files are
in the allwinner directory.

Provide a work-around for this particular case.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Tom Rini <trini@konsulko.com>
2024-12-05 13:58:19 -07:00
Simon Glass
0fcdf0a251 sunxi: Drop old distro boot variables
These are not needed as bootstd handles the boot now. Drop them.

Keep BOOTCMD_SUNXI_COMPAT for now since it does not relate to
distro boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 13:58:19 -07:00
Simon Glass
c24a79fdb2 sunxi: Move to bootstd
Drop support for distroboot and move to using bootstd instead.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 13:58:19 -07:00
Simon Glass
c51ec357b9 efi_loader: bootstd: Drop bootmgr for sunxi
This causes problems with the boot order, so drop it until we can figure
out a better way to know when bootmgr should be used.

Link: https://lore.kernel.org/u-boot/20241112171205.4e80548d@donnerap.manchester.arm.com/

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 13:58:19 -07:00
Simon Glass
daa627d03a sunxi: Add a bootmeth for FEL
Add support for booting from a script loaded over FEL. This mirrors the
bootcmd_fel provided by distro boot.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
2024-12-05 13:58:18 -07:00
Tom Rini
b05c4c1c50 arm: sunxi: Use "imply" for USB without further guards
Given that ARCH_SUNXI already implies that USB_GADGET should be enable,
we should also imply USB being enabled.

Signed-off-by: Tom Rini <trini@konsulko.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
2024-12-05 13:11:44 -07:00
Tom Rini
a031cfd76b efi_loader: Fix Kconfig logic around OF_LIBFDT
Given that OF_LIBFDT is library functionality, the feature of EFI_LOADER
needs to select OF_LIBFDT rather than depend on it being already
enabled.

Signed-off-by: Tom Rini <trini@konsulko.com>
Acked-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
2024-12-05 13:11:44 -07:00
Tom Rini
32e4436edc aspeed: Fix Kconfig logic on "DM_REGULATOR" and ASPEED_AST2500
It is not the case that we can only pick ASPEED_AST2500 if DM_REGULATOR
is enabled, but rather choosing ASPEED_AST2500 means we must select
DM_REGULATOR.

Signed-off-by: Tom Rini <trini@konsulko.com>
2024-12-05 13:11:44 -07:00
Simon Glass
5ff6bb8f10 Merge branch 'ci' into 'master'
bootstd: Move bootflow-adding to bootstd

See merge request u-boot/u-boot!6
2024-12-05 19:58:02 +00:00
Simon Glass
e7100b4c37 Revert "power: regulator: Trigger probe of regulators which are always-on or boot-on"
Unfortunately this commit causes a problem on nyan-big:

   U-Boot SPL 2024.10-rc6-00632-g51c4679d2f84 (Nov 30 2024 - 13:28:40 -0700)
   Trying to boot from RAM

   U-Boot 2024.10-rc6-00632-g51c4679d2f84 (Nov 30 2024 - 13:28:40 -0700)

   SoC: tegra124
   Reset cause: POR
   Model: Acer Chromebook 13 CB5-311
   Board: Google/NVIDIA Nyan-big, ID: -2
   DRAM:  2 GiB
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   failed to read ID1 register: -121
   failed to read ID: -121
   Unknown PLL id 14
   failed to read ID1 register: -121
   failed to read ID: -121
   initcall failed at call 810029c8 (err=-121: Remote I/O error)
   ### ERROR ### Please RESET the board ###

This reverts commit 51c4679d2f.

Tweak a few tests also, so they continue to pass.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
1b244135e2 fdt: Allow the devicetree to come from a bloblist
Standard passage provides for a bloblist to be passed from one firmware
phase to the next. That can be used to pass the devicetree along as well.
Add an option to support this.

Tests for this will be added as part of the Universal Payload work.

Note: This is the correct way to deal with bloblist, since it allows
boards to choose whether they want to use the devicetree from there, or
not.

Link: https://patchwork.ozlabs.org/project/uboot/patch/20231226094625.221671-1-sjg@chromium.org/
Link: https://patchwork.ozlabs.org/project/uboot/patch/20231228133654.2356023-1-sjg@chromium.org/
Link: https://patchwork.ozlabs.org/project/uboot/patch/20231228194725.2482268-1-sjg@chromium.org/
Link: https://patchwork.ozlabs.org/project/uboot/patch/20240104014919.413568-1-sjg@chromium.org/
Link: https://patchwork.ozlabs.org/project/uboot/patch/20230921015730.1511373-31-sjg@chromium.org/
Link: https://patchwork.ozlabs.org/project/uboot/patch/20230830180524.315916-31-sjg@chromium.org/

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
0938c3a7a7 Revert "fdt: Allow the devicetree to come from a bloblist"
This stops coral, bob and kevin from booting.

The correct way to do this was always to use a Kconfig option, so let's
first revert this broken idea.

This reverts commit 70fe238594.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
39904788e6 Revert "fdt: Correct condition for bloblist existing"
This was a work-around and it isn't effective, since bob and kevin are
still broken. Drop it.

This reverts commit cafde93ec0.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
e4b32ec92f CI: Drop broken boards from sjg lab
Some of the boards have developed problems since the last passing run.

Disable these while diagnosis is ongoing.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
c2ca92d2ee CI: Drop extra condition for sjg lab
The rules part of the template makes sure that this doesn't run until
specifically requested. Drop the check in the script itself, so it is
possible to trigger a run manually without re-pushing the tree.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
9820ce9a2f fs: Record loaded files in an ad-hoc bootflow
This makes a start on dealing with images loaded outside the context of
bootstd. For now, it just records these images. They can be listed using
the 'bootstd images' command.

Often, very little is known about these images, but future work could
perhaps use the filename or contents to detect the type.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
f2f04db05e bootstd: Add the concept of an ad-hoc bootflow
The normal situation with bootstd is that a bootflow is created from a
bootmeth. In some cases, a script or user-command may cause an image to
be loaded. To deal with this, add the concept of an ad-hoc bootflow.
This can be used to record information about manually loaded images.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
1cdfc6aa2d bootstd: Export bootdev_get_from_blk()
Export this function so it can be used from other files.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
ab0887ffdf bootstd: Add a simple command to list images
Add a new 'bootstd images' command, which lists the images which have
been loaded.

Update some existing tests to use it. Provide some documentation about
images in general and this command in particular.

Use a more realistic kernel command-line to make the test easier to
follow.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00
Simon Glass
69612b4aef bootstd: Update cros bootmeth to record images
Record images loaded by this bootmeth.

Signed-off-by: Simon Glass <sjg@chromium.org>
2024-12-05 11:00:23 -07:00