Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 9 Mar 2004 01:46:45 +0100
From:      Stefan `Sec` Zehl <sec@42.org>
To:        Brooks Davis <brooks@one-eyed-alien.net>
Cc:        FreeBSD-gnats-submit@freebsd.org
Subject:   Re: kern/63772: tap device / exclusive open problem
Message-ID:  <20040309004645.GD55352@ice.42.org>
In-Reply-To: <20040305185527.GA16862@Odin.AC.HMC.Edu>
References:  <20040304191443.67E9B1C8BA@ice.42.org> <200403041920.i24JK826047989@freefall.freebsd.org> <20040305181852.GC21713@ice.42.org> <20040305185527.GA16862@Odin.AC.HMC.Edu>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Mar 05, 2004 at 10:55 -0800, Brooks Davis wrote:

[...]

> >         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);
> > +
[...]


> 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.

I must admit, I don't understand the problem. this is an really simple
if. Nothing is modified, and tp is not NULL, or the KASSERT above would
be broken already.

How do you get it to panic?

It works fine for me.

CU,
    Sec
-- 
In 1968 it took the computing-Power of 2 C-64 to fly a rocket to the moon.
Now, 1997 it takes the Power of a Pentium 133 to run Microsoft Windows 95.
                    Something must have gone wrong.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040309004645.GD55352>