diff options
| author | Simon Glass <[email protected]> | 2025-05-02 08:46:28 -0600 |
|---|---|---|
| committer | Simon Glass <[email protected]> | 2025-05-30 09:49:32 +0100 |
| commit | da754e20c99a0e611b05c74f9e28daf9cdf1a199 (patch) | |
| tree | 8a30fdef4f8288e69044a0aa914cbbeed2cee079 /include | |
| parent | b991a0c8bf30095837b096acd691e0d2add07b8c (diff) | |
expo: Split bootflow_menu_new() into two pieces
Split the iteration piece of this function into bootflow_menu_add_all()
so that it is possible for the caller to be in control of adding items
to the menu.
Move the expo_destroy() call into the caller.
Signed-off-by: Simon Glass <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/bootflow.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/include/bootflow.h b/include/bootflow.h index 8244d4fca18..994b38394e8 100644 --- a/include/bootflow.h +++ b/include/bootflow.h @@ -488,12 +488,25 @@ int bootflow_iter_check_system(const struct bootflow_iter *iter); /** * bootflow_menu_new() - Create a new bootflow menu * + * This is initially empty. Call bootflow_menu_add_all() to add all the + * bootflows to it. + * * @expp: Returns the expo created * Returns 0 on success, -ve on error */ int bootflow_menu_new(struct expo **expp); /** + * bootflow_menu_add_all() - Add all bootflows to a menu + * + * Loops through all bootflows and adds them to the menu + * + * @exp: Menu to update + * Return 0 on success, -ve on error + */ +int bootflow_menu_add_all(struct expo *exp); + +/** * bootflow_menu_apply_theme() - Apply a theme to a bootmenu * * @exp: Expo to update |
