aboutsummaryrefslogtreecommitdiff
path: root/include/os.h
diff options
context:
space:
mode:
authorSimon Glass2021-07-05 16:32:45 -0600
committerSimon Glass2021-07-21 10:27:34 -0600
commitf178bebf551a43445ba8f1e1a4c1638eff8eb612 (patch)
treec36bf045cdad0eb02691bb999ba6f734e330c220 /include/os.h
parent719d286475d2df1f1d8f4413659893934f38de7d (diff)
sandbox: Support executables for more phases
The SPL header has a function for obtaining the phase in capital letters, e.g. 'SPL'. Add one for lower-case also, as used by sandbox. Use this to generalise the sandbox logic for determining the filename of the next sandbox executable. This can provide support for VPL. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/os.h')
-rw-r--r--include/os.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/os.h b/include/os.h
index bd1096eb8b3..7b20d606dd0 100644
--- a/include/os.h
+++ b/include/os.h
@@ -327,9 +327,12 @@ int os_jump_to_image(const void *dest, int size);
* @fname: place to put full path to U-Boot
* @maxlen: maximum size of @fname
* @use_img: select the 'u-boot.img' file instead of the 'u-boot' ELF file
+ * @cur_prefix: prefix of current executable, e.g. "spl" or "tpl"
+ * @next_prefix: prefix of executable to find, e.g. "spl" or ""
* Return: 0 if OK, -NOSPC if the filename is too large, -ENOENT if not found
*/
-int os_find_u_boot(char *fname, int maxlen, bool use_img);
+int os_find_u_boot(char *fname, int maxlen, bool use_img,
+ const char *cur_prefix, const char *next_prefix);
/**
* os_spl_to_uboot() - Run U-Boot proper