diff options
| author | Simon Glass <[email protected]> | 2025-03-05 17:25:14 -0700 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2025-03-18 13:12:15 -0600 |
| commit | e2e87b840162ddf4ec8df3f235be98a74a964509 (patch) | |
| tree | fb714298e767eb7fc4e66030314ba561b3992a70 /arch | |
| parent | feb8d7fd749413e889ba2c396654f473ba32034d (diff) | |
boot: pxe: Refactor label_run_boot() to avoid cmdline
Adjust the remaining call in this function to use the bootm API. This
will allow PXE to work without the command line.
Signed-off-by: Simon Glass <[email protected]>
Diffstat (limited to 'arch')
| -rw-r--r-- | arch/x86/lib/zimage.c | 27 |
1 files changed, 19 insertions, 8 deletions
diff --git a/arch/x86/lib/zimage.c b/arch/x86/lib/zimage.c index 145ba0b8ea0..ba7a008fec7 100644 --- a/arch/x86/lib/zimage.c +++ b/arch/x86/lib/zimage.c @@ -432,27 +432,38 @@ int zboot_go(struct bootm_info *bmi) return ret; } -int zboot_run_args(ulong addr, ulong size, ulong initrd, ulong initrd_size, - ulong base, char *cmdline) +int zboot_run(struct bootm_info *bmi) { - struct bootm_info bmi; int ret; - bootm_init(&bmi); - zboot_start(&bmi, addr, size, initrd, initrd_size, base, cmdline); - ret = zboot_load(&bmi); + ret = zboot_load(bmi); if (ret) return log_msg_ret("ld", ret); - ret = zboot_setup(&bmi); + ret = zboot_setup(bmi); if (ret) return log_msg_ret("set", ret); - ret = zboot_go(&bmi); + ret = zboot_go(bmi); if (ret) return log_msg_ret("go", ret); return -EFAULT; } +int zboot_run_args(ulong addr, ulong size, ulong initrd, ulong initrd_size, + ulong base, char *cmdline) +{ + struct bootm_info bmi; + int ret; + + bootm_init(&bmi); + zboot_start(&bmi, addr, size, initrd, initrd_size, base, cmdline); + ret = zboot_run(&bmi); + if (ret) + return log_msg_ret("zra", ret); + + return 0; +} + static void print_num(const char *name, ulong value) { printf("%-20s: %lx\n", name, value); |
