diff options
author | Simon Glass <sjg@chromium.org> | 2022-10-21 03:23:10 +0300 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2022-10-31 18:03:18 +0300 |
commit | d2b22ae23196604fda88e1ad9ec9f0e8fd285d07 (patch) | |
tree | de0c2bdf2ab67e2f95be3b1194ce1db53fe87f5e /boot/vbe_simple.h | |
parent | 70b26e4356f9153d2d8195748a0e146c35b0c42e (diff) | |
download | u-boot-d2b22ae23196604fda88e1ad9ec9f0e8fd285d07.tar.xz |
vbe: Support reading the next SPL phase via VBE
Add an SPL loader to obtain the next-phase binary from a FIT provided
by the VBE driver.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'boot/vbe_simple.h')
-rw-r--r-- | boot/vbe_simple.h | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/boot/vbe_simple.h b/boot/vbe_simple.h new file mode 100644 index 0000000000..e37a9fae37 --- /dev/null +++ b/boot/vbe_simple.h @@ -0,0 +1,37 @@ +/* SPDX-License-Identifier: GPL-2.0 */ +/* + * Verified Boot for Embedded (VBE) vbe-simple common file + * + * Copyright 2022 Google LLC + * Written by Simon Glass <sjg@chromium.org> + */ + +#ifndef __VBE_SIMPLE_H +#define __VBE_SIMPLE_H + +/** struct simple_priv - information read from the device tree */ +struct simple_priv { + u32 area_start; + u32 area_size; + u32 skip_offset; + u32 state_offset; + u32 state_size; + u32 version_offset; + u32 version_size; + const char *storage; +}; + +/** + * vbe_simple_read_fw_bootflow() - Read a bootflow for firmware + * + * Locates and loads the firmware image (FIT) needed for the next phase. The FIT + * should ideally use external data, to reduce the amount of it that needs to be + * read. + * + * @bdev: bootdev device containing the firmwre + * @blow: Place to put the created bootflow, on success + * @return 0 if OK, -ve on error + */ +int vbe_simple_read_bootflow_fw(struct udevice *dev, struct bootflow *bflow); + +#endif /* __VBE_SIMPLE_H */ |