From owner-freebsd-bugs@FreeBSD.ORG Fri Mar 5 11:00:26 2004 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2E92C16A4CE for ; Fri, 5 Mar 2004 11:00:26 -0800 (PST) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2937143D2D for ; Fri, 5 Mar 2004 11:00:26 -0800 (PST) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) i25J0Obv096801 for ; Fri, 5 Mar 2004 11:00:24 -0800 (PST) (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.12.10/8.12.10/Submit) id i25J0NpN096800; Fri, 5 Mar 2004 11:00:23 -0800 (PST) (envelope-from gnats) Date: Fri, 5 Mar 2004 11:00:23 -0800 (PST) Message-Id: <200403051900.i25J0NpN096800@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org From: Brooks Davis Subject: Re: kern/63772: tap device / exclusive open problem X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list Reply-To: Brooks Davis List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Mar 2004 19:00:26 -0000 The following reply was made to PR kern/63772; it has been noted by GNATS. From: Brooks Davis To: Stefan `Sec` Zehl Cc: FreeBSD-gnats-submit@freebsd.org, freebsd-bugs@freebsd.org Subject: Re: kern/63772: tap device / exclusive open problem Date: Fri, 5 Mar 2004 10:55:30 -0800 On Fri, Mar 05, 2004 at 07:18:52PM +0100, Stefan `Sec` Zehl wrote: > On Thu, Mar 04, 2004 at 11:20 -0800, FreeBSD-gnats-submit@FreeBSD.org wrote: > > Thank you very much for your problem report. > > It has the internal identification `kern/63772'. > > I have checked the if_tap.c in the current and stable branches, and was > thus able to come up with an easy fix: > > --- if_tap.c Tue Feb 24 05:35:44 2004 > +++ if_tap.c.neu Fri Mar 5 19:09:12 2004 > @@ -323,6 +323,9 @@ > KASSERT(!(tp->tap_flags & TAP_OPEN), > ("%s flags is out of sync", tp->tap_if.if_xname)); > > + if (tp->tap_flags & TAP_OPEN) > + return (EBUSY); > + > bcopy(tp->arpcom.ac_enaddr, tp->ether_addr, sizeof(tp->ether_addr)); > > tp->tap_pid = td->td_proc->p_pid; > > > After this simple change, openvpn works with multiple tunnels again. There's obviously something complicated going on since with INVARIANTS enabled this would either return EBUSY or panic. This should definitely not be committed as is. -- Brooks