summaryrefslogtreecommitdiffstats
path: root/src/if.h
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2020-09-22 13:09:03 +0100
committerRoy Marples <roy@marples.name>2020-09-22 13:09:03 +0100
commit0ede9e5419b798ae5ed183ca7da7986b8d4419bd (patch)
treeb009feff69e39b125f76f361174635b6e2877b14 /src/if.h
parent96bf083104435f38e06375fbaa094ab50626b5de (diff)
downloaddhcpcd-0ede9e5419b798ae5ed183ca7da7986b8d4419bd.tar.xz
BSD: Detect initial link state in ifa_data
Not all interfaces report media state to get the link state. However, link state is available from getifaddrs(3) ifa_data for AF_LINK addresses. Testing shows that link state is also sent correctly via route(4) messages for the same interface. This makes pppoe(4) interfaces more reliable on FreeBSD and OpenBSD.
Diffstat (limited to 'src/if.h')
-rw-r--r--src/if.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/if.h b/src/if.h
index 4e8302ba..7123c3a1 100644
--- a/src/if.h
+++ b/src/if.h
@@ -160,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_carrier_ifadata(struct interface *, void *);
int if_pollinit(struct interface *ifp);
#ifdef ALIAS_ADDR