mirror of
https://github.com/ipxe/ipxe
synced 2026-04-16 03:00:10 +03:00
[fdt] Populate boot arguments in constructed device tree
When creating a device tree to pass to a booted operating system, ensure that the "chosen" node exists, and populate the "bootargs" property with the image command line. Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -107,13 +107,14 @@ static struct fdt_header *efi_fdt_installed;
|
||||
/**
|
||||
* Install EFI Flattened Device Tree table
|
||||
*
|
||||
* @v cmdline Command line, or NULL
|
||||
* @ret rc Return status code
|
||||
*/
|
||||
int efi_fdt_install ( void ) {
|
||||
int efi_fdt_install ( const char *cmdline ) {
|
||||
int rc;
|
||||
|
||||
/* Create device tree */
|
||||
if ( ( rc = fdt_create ( &efi_fdt_installed ) ) != 0 ) {
|
||||
if ( ( rc = fdt_create ( &efi_fdt_installed, cmdline ) ) != 0 ) {
|
||||
DBGC ( &efi_fdt, "EFI_FDT could not install: %s\n",
|
||||
strerror ( rc ) );
|
||||
goto err_create;
|
||||
|
||||
Reference in New Issue
Block a user