aboutsummaryrefslogtreecommitdiff
path: root/boot
diff options
context:
space:
mode:
authorShantur Rathore <i@shantur.com>2023-11-19 16:54:58 +0000
committerTom Rini <trini@konsulko.com>2023-12-09 13:16:08 -0500
commitc5440a6ae85d0b68e511c1b0b81dc97a3df719e5 (patch)
treeb86903534244c10a3ccbf987d7e24f1800685817 /boot
parent741d1e9d3f368908e3cd1861ddd707e81e1fd576 (diff)
bootflow: bootmeth_efi: Set bootp_arch as hex
bootmeth_efi sets up bootp_arch which is read later in bootp.c Currently bootp_arch is being set as integer string and being read in bootp.c as hex, this sends incorrect arch value to dhcp server which in return sends wrong file for network boot. For ARM64 UEFI Arch value is 0xb (11), here we set environment as 11 and later is read as 0x11 and 17 is sent to dhcp server. Setting it as hex string fixes the problem. Reviewed-by: Simon Glass <sjg@chromium.org> Signed-off-by: Shantur Rathore <i@shantur.com>
Diffstat (limited to 'boot')
-rw-r--r--boot/bootmeth_efi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/boot/bootmeth_efi.c b/boot/bootmeth_efi.c
index 9ba7734911..682cf5b23b 100644
--- a/boot/bootmeth_efi.c
+++ b/boot/bootmeth_efi.c
@@ -339,7 +339,7 @@ static int distro_efi_read_bootflow_net(struct bootflow *bflow)
ret = env_set("bootp_vci", str);
if (ret)
return log_msg_ret("vcs", ret);
- ret = env_set_ulong("bootp_arch", arch);
+ ret = env_set_hex("bootp_arch", arch);
if (ret)
return log_msg_ret("ars", ret);