From: Arjan Minzinga Zijlstra Date: Thu, 31 Mar 2022 08:03:16 +0000 (+0000) Subject: net: tftp: fix tftp server initialization X-Git-Tag: v2022.07~100^2~20 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1ffe366881a3fd474737f67f2e9fb5bf40104fd3;p=platform%2Fkernel%2Fu-boot.git net: tftp: fix tftp server initialization Some globals where not properly initialized causing timeouts as data packets where not immediately acknowledged. Fixes: cc6b87ecaa96 ("net: tftp: Add client support for RFC 7440") Signed-off-by: Arjan Minzinga Zijlstra Reviewed-by: Ramon Fried --- diff --git a/net/tftp.c b/net/tftp.c index e1e3597..bfc4c9b 100644 --- a/net/tftp.c +++ b/net/tftp.c @@ -906,6 +906,8 @@ void tftp_start_server(void) tftp_block_size = TFTP_BLOCK_SIZE; tftp_cur_block = 0; tftp_our_port = WELL_KNOWN_PORT; + tftp_windowsize = 1; + tftp_next_ack = tftp_windowsize; #ifdef CONFIG_TFTP_TSIZE tftp_tsize = 0;