arm64: configs: Remove SYS_BOOTM_LEN for TI devices
[u-boot.git] / boot / vbe_simple.h
blobdc3f70052b0f6a0e071bade5eb0e48f989671d21
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3 * Verified Boot for Embedded (VBE) vbe-simple common file
5 * Copyright 2022 Google LLC
6 * Written by Simon Glass <sjg@chromium.org>
7 */
9 #ifndef __VBE_SIMPLE_H
10 #define __VBE_SIMPLE_H
12 #include <linux/types.h>
13 #include "vbe_common.h"
15 /** struct simple_priv - information read from the device tree */
16 struct simple_priv {
17 u32 area_start;
18 u32 area_size;
19 u32 skip_offset;
20 u32 state_offset;
21 u32 state_size;
22 u32 version_offset;
23 u32 version_size;
24 const char *storage;
27 /** struct simple_state - state information read from media
29 * @fw_version: Firmware version string
30 * @fw_vernum: Firmware version number
32 struct simple_state {
33 char fw_version[MAX_VERSION_LEN];
34 u32 fw_vernum;
37 /**
38 * vbe_simple_read_fw_bootflow() - Read a bootflow for firmware
40 * Locates and loads the firmware image (FIT) needed for the next phase. The FIT
41 * should ideally use external data, to reduce the amount of it that needs to be
42 * read.
44 * @bdev: bootdev device containing the firmwre
45 * @blow: Place to put the created bootflow, on success
46 * @return 0 if OK, -ve on error
48 int vbe_simple_read_bootflow_fw(struct udevice *dev, struct bootflow *bflow);
50 /**
51 * vbe_simple_read_state() - Read the VBE simple state information
53 * @dev: VBE bootmeth
54 * @state: Place to put the state
55 * @return 0 if OK, -ve on error
57 int vbe_simple_read_state(struct udevice *dev, struct simple_state *state);
59 #endif /* __VBE_SIMPLE_H */