summaryrefslogtreecommitdiffstats
path: root/usr.sbin/ripd/interface.c
diff options
context:
space:
mode:
authorreyk <reyk@openbsd.org>2006-11-28 19:21:15 +0000
committerreyk <reyk@openbsd.org>2006-11-28 19:21:15 +0000
commit307627386806be0bc5eb7752d727b7ee499ed0a7 (patch)
tree9f8c64c381831baefec1b2e0e88a0893c9706702 /usr.sbin/ripd/interface.c
parentSupport "trace /p <pid>" to show the stack trace of any process. (diff)
downloadwireguard-openbsd-307627386806be0bc5eb7752d727b7ee499ed0a7.tar.xz
wireguard-openbsd-307627386806be0bc5eb7752d727b7ee499ed0a7.zip
add additional link states to report the half duplex / full duplex
state, if known by the driver. this is required to check the full duplex state without depending on the ifmedia ioctl which can't be called in the kernel without process context. ok henning@, brad@
Diffstat (limited to 'usr.sbin/ripd/interface.c')
-rw-r--r--usr.sbin/ripd/interface.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/ripd/interface.c b/usr.sbin/ripd/interface.c
index be9917361ad..f5ecc524102 100644
--- a/usr.sbin/ripd/interface.c
+++ b/usr.sbin/ripd/interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: interface.c,v 1.1 2006/10/18 16:11:58 norby Exp $ */
+/* $OpenBSD: interface.c,v 1.2 2006/11/28 19:21:15 reyk Exp $ */
/*
* Copyright (c) 2006 Michele Marchetto <mydecay@openbeer.it>
@@ -159,7 +159,7 @@ if_act_start(struct iface *iface)
}
if (!((iface->flags & IFF_UP) &&
- (iface->linkstate == LINK_STATE_UP ||
+ (LINK_STATE_IS_UP(iface->linkstate) ||
(iface->linkstate == LINK_STATE_UNKNOWN &&
iface->media_type != IFT_CARP)))) {
log_debug("if_act_start: interface %s link down",