Date: Wed, 26 May 1999 13:48:16 +0100 From: Brian Somers <brian@Awfulhak.org> To: freebsd-hackers@FreeBSD.org Subject: Interface UP & RUNNING flags Message-ID: <199905261248.NAA00647@keep.lan.Awfulhak.org>
next in thread | raw e-mail | index | archive | help
Hi, Can someone tell me the difference between the IFF_UP and IFF_RUNNING flags ? Currently, the tun pseudo-device never bothers removing the RUNNING flag. This can easily be fixed with Index: if_tun.c =================================================================== RCS file: /home/ncvs/src/sys/net/if_tun.c,v retrieving revision 1.55 diff -u -r1.55 if_tun.c --- if_tun.c 1999/05/06 18:12:54 1.55 +++ if_tun.c 1999/05/26 12:30:55 @@ -210,6 +210,13 @@ } splx(s); } + + if (ifp->if_flags & IFF_RUNNING) { + s = splimp(); + ifp->if_flags &= ~IFF_RUNNING; + splx(s); + } + funsetown(tp->tun_sigio); selwakeup(&tp->tun_rsel); But is this the right fix ? Should IFF_RUNNING be removed with the last address - for *all* interfaces ? Cheers. -- Brian <brian@Awfulhak.org> <brian@FreeBSD.org> <http://www.Awfulhak.org> <brian@OpenBSD.org> Don't _EVER_ lose your sense of humour ! <brian@uk.FreeBSD.org> To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199905261248.NAA00647>