bootstd: Read the Operating System name for distro/scripts

Add the concept of an OS name to the bootflow. This typically includes the
OS name, version and kernel version.

Implement this for the distro and script bootmeths so that it works with
Armbian and older version of Fedora.

Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
Simon Glass
2023-01-16 18:26:50 -05:00
committed by Tom Rini
parent 0e38bd848d
commit 2175e76a51
6 changed files with 76 additions and 0 deletions
+3
View File
@@ -52,6 +52,8 @@ enum bootflow_state_t {
* @buf: Bootflow file contents (allocated)
* @size: Size of bootflow file in bytes
* @err: Error number received (0 if OK)
* @os_name: Name of the OS / distro being booted, or NULL if not known
* (allocated)
*/
struct bootflow {
struct list_head bm_node;
@@ -68,6 +70,7 @@ struct bootflow {
char *buf;
int size;
int err;
char *os_name;
};
/**