1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-13 10:02:38 +00:00
freebsd/stand/libsa
Kyle Evans 502b7cf99b libsa: Fix IP recv timeout
readip() doesn't, at the moment, properly indicate to callers that it has
timed out. One can tell that it's timed out if errno == EAGAIN when it
returns, but this is not ideal. Restructure it a little bit to explicitly
set errno to ETIMEDOUT if we've exhausted tleft.

I found two places that care about where it timed out or not: sendrecv in
net.c and sendrecv_tftp. Both are structured to pass smaller timeout values
to readip while tracking a larger timeout. Neither of them were able to do
this properly with readip not indicating ETIMEDOUT, so fix it.

While here, straighten out the time (t/t1) usage in sendrecv_tftp.

This would have manifested itself in periodic failures to NFS/TFTP boot for
no apparent reason because MINTMO/MAXTMO were not actually being respected
properly. Problems were not reported with NFS, only TFTP.

Reported by:	sbruno
Reviewed by:	sbruno, tsoome
MFC after:	3 days
Differential Revision:	https://reviews.freebsd.org/D14350
2018-02-14 15:40:13 +00:00
..
amd64
i386
mips
powerpc
sparc64
__main.c
abort.c Implement abort() as a call to panic. 2018-01-26 17:13:04 +00:00
arp.c
assert.c
bcd.c
bootp.c dhcp_try_rfc1048() is not used any more 2017-12-06 06:49:53 +00:00
bootp.h dhcp_try_rfc1048() is not used any more 2017-12-06 06:49:53 +00:00
bootparam.c
bootparam.h
bzipfs.c
cd9660.c Use the kernel relative paths, rather than the userland relative paths 2017-12-05 21:37:50 +00:00
close.c
closeall.c
crc32.c
crc32.h
dev.c
dosfs.c
dosfs.h
environment.c getenv does not return tainted data in the boot loader. Attempt to 2018-01-23 18:01:36 +00:00
ether.c
ext2fs.c
fstat.c
getopt.c
gets.c
globals.c
gpt.c Remove the 'mini libstand in libstand' that util.[ch] provided. These 2017-12-15 23:16:53 +00:00
gpt.h
gzipfs.c
in_cksum.c
inet_ntoa.c
ioctl.c
iodesc.h
ip.c libsa: Fix IP recv timeout 2018-02-14 15:40:13 +00:00
libsa.3 Move libstand.3 to libsa.3. Update libsa.3 to include functions 2018-01-31 04:29:05 +00:00
lseek.c
Makefile Centralize several variables. 2018-02-02 06:32:26 +00:00
Makefile.depend
nandfs.c
net.c libsa: Fix IP recv timeout 2018-02-14 15:40:13 +00:00
net.h Move getsecs() prototype to stand.h from net.h so it can be used 2018-01-12 16:28:51 +00:00
netif.c
netif.h
nfs.c
nfsv2.h
nullfs.c
open.c
pager.c
panic.c Split panic routine 2018-01-26 17:13:00 +00:00
pkgfs.c
printf.c
qdivrem.c
quad.h
random.c Fix random() and srandom() prototypes to match the standard. 2017-12-02 00:07:19 +00:00
rarp.c
read.c
readdir.c
rpc.c
rpc.h
rpcv2.h
saioctl.h
sbrk.c Panic in sbrk if setheap hasn't been called yet. This is preferable to 2017-12-15 23:16:47 +00:00
splitfs.c
stand.h Implement strcoll as strcmp. 2018-02-02 21:18:32 +00:00
stat.c
strcasecmp.c
strdup.c
strerror.c
tftp.c libsa: Fix IP recv timeout 2018-02-14 15:40:13 +00:00
tftp.h
twiddle.c
udp.c
ufs.c Refactoring of reading and writing of the UFS/FFS superblock. 2018-01-26 00:58:32 +00:00
ufsread.c
uuid_from_string.c
uuid_to_string.c
write.c
xlocale_private.h Kill copies of strtol and strtoul. Use the ones that are in libc, 2018-01-31 04:29:00 +00:00
zalloc_defs.h
zalloc_malloc.c
zalloc_mem.h
zalloc_protos.h
zalloc.c