summaryrefslogtreecommitdiffstats
path: root/src/if.h
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2020-06-18 21:15:15 +0100
committerRoy Marples <roy@marples.name>2020-06-18 21:15:15 +0100
commit009dc39be56be9b2fae857e64aa55c20f2842d13 (patch)
tree6085381f2e63161a8aa72f49eaac34f255f970be /src/if.h
parent3f9355273c90c21bb1fdaa8bac9776f8195301b2 (diff)
downloaddhcpcd-009dc39be56be9b2fae857e64aa55c20f2842d13.tar.xz
dhcpcd: Add an option to poll the interface carrier state
Only to be used if the interface does not report carrier state changes for whatever reason.
Diffstat (limited to 'src/if.h')
-rw-r--r--src/if.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/if.h b/src/if.h
index 8abf079a..2323501f 100644
--- a/src/if.h
+++ b/src/if.h
@@ -38,6 +38,10 @@
#include <ifaddrs.h>
+/* If the interface does not support carrier status (ie PPP),
+ * dhcpcd can poll it for the relevant flags periodically */
+#define IF_POLL_UP 100 /* milliseconds */
+
/* Some systems have in-built IPv4 DAD.
* However, we need them to do DAD at carrier up as well. */
#ifdef IN_IFF_TENTATIVE
@@ -156,6 +160,7 @@ int if_domtu(const struct interface *, short int);
#define if_getmtu(ifp) if_domtu((ifp), 0)
#define if_setmtu(ifp, mtu) if_domtu((ifp), (mtu))
int if_carrier(struct interface *);
+int if_pollinit(struct interface *ifp);
#ifdef ALIAS_ADDR
int if_makealias(char *, size_t, const char *, int);