aboutsummaryrefslogtreecommitdiff
path: root/stand/libsa/net.c
diff options
context:
space:
mode:
Diffstat (limited to 'stand/libsa/net.c')
-rw-r--r--stand/libsa/net.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/stand/libsa/net.c b/stand/libsa/net.c
index 9f2eabb1da9c..e0f8e8a208e8 100644
--- a/stand/libsa/net.c
+++ b/stand/libsa/net.c
@@ -58,6 +58,20 @@ __FBSDID("$FreeBSD$");
#include "net.h"
/*
+ * Maximum wait time for sending and receiving before we give up and timeout.
+ * If set to 0, operations will eventually timeout completely, but send/recv
+ * timeouts must progress exponentially from MINTMO to MAXTMO before final
+ * timeout is hit.
+ */
+#ifndef MAXWAIT
+#define MAXWAIT 0 /* seconds */
+#endif
+
+#if MAXWAIT < 0
+#error MAXWAIT must not be a negative number
+#endif
+
+/*
* Send a packet and wait for a reply, with exponential backoff.
*
* The send routine must return the actual number of bytes written,