]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
net: bootp: Correct VCI string transmission
authorWalter Stoll <walter.stoll@duagon.com>
Tue, 12 Oct 2021 11:01:59 +0000 (11:01 +0000)
committerRamon Fried <rfried.dev@gmail.com>
Tue, 23 Nov 2021 07:57:56 +0000 (09:57 +0200)
The VCI string sent during bootp of U-Boot-SPL is corrupt. This is
because the byte counter is not adjusted within the bootp_extended()
function when the VCI string is added. We fix this.

Signed-off-by: Walter Stoll <walter.stoll@duagon.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
net/bootp.c

index 655b9cceb669aca2bf206bb1c460b788e88c056c..58e30cd6b0c52459ce5ead0e29574ba5bbdaf5e2 100644 (file)
@@ -647,7 +647,7 @@ static int bootp_extended(u8 *e)
        *e++ = (576 - 312 + OPT_FIELD_SIZE) & 0xff;
 #endif
 
-       add_vci(e);
+       e = add_vci(e);
 
 #if defined(CONFIG_BOOTP_SUBNETMASK)
        *e++ = 1;               /* Subnet mask request */