Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 Aug 2005 21:43:05 +0300
From:      Maxim Sobolev <sobomax@portaone.com>
To:        John Baldwin <jhb@FreeBSD.ORG>
Cc:        cvs-src@FreeBSD.ORG, src-committers@FreeBSD.ORG, cvs-all@FreeBSD.ORG
Subject:   Re: cvs commit: src/sys/dev/re if_re.c
Message-ID:  <4304D6B9.8050603@portaone.com>
In-Reply-To: <200508181238.05411.jhb@FreeBSD.org>
References:  <200508181429.j7IET16d038533@repoman.freebsd.org> <200508181238.05411.jhb@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
John Baldwin wrote:
> On Thursday 18 August 2005 10:29 am, Maxim Sobolev wrote:
> 
>>sobomax     2005-08-18 14:29:01 UTC
>>
>>  FreeBSD src repository
>>
>>  Modified files:
>>    sys/dev/re           if_re.c
>>  Log:
>>  In re_shutdown() mark interface as down since otherwise we will panic if
>>  interrupt comes in later on, which can happen in some uncommon cases.
>>
>>  Another possible fix is to call re_detach() instead of re_stop(), like
>>  ve(4) does, but I am not sure if the latter is really RTTD, so that stick
>>  with this one-liner for now.
>>
>>  PR:             kern/80005
>>  Approved by:    silence on -arch, no reply from selected network gurus
> 
> 
> The PR reports problems while the machine is running, not a panic during 
> shutdown.  I couldn't get the PR database to load the PR with the panic from 

Sorry, it has been a typo - in fact I was reffering to kern/85005.

> vr(4) yesterday.  It's very unclear why clearing IFF_UP makes any difference.  
> Ah, perhaps re_intr() should be fixed to check IFF_DRV_RUNNING rather than 
> IFF_UP?  Then the re_stop() in re_shutdown() would be sufficient.

Yes, this will help. However, I am not quite sure, what is the point to 
do interrupt processing if interface is down? Perhaps re_intr() should 
check both IFF_DRV_RUNNING and IFF_UP?

> I also think that the change to vr(4) should be reverted (way too big of a 
> sledge hammer) and instead its interrupt handler can check IFF_DRV_RUNNING 
> and bail if it is clear as well.

Well, see kern/85005. IMO some generic approach should be worked out and 
implemented since I think many other network drivers may be affected by 
the same problem.

-Maxim



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