Re: network slowness/freez-up since update 10/11

From: Robert Watson <rwatson_at_freebsd.org>
Date: Thu, 14 Oct 2004 04:45:02 -0400 (EDT)
On Wed, 13 Oct 2004, Bruce M Simpson wrote:

> On Wed, Oct 13, 2004 at 04:27:22PM -0400, Robert Watson wrote:
> > There appears to bea problem with if_de cards and Giant-free operation.
> > I'm working with John Baldwin to try and diagnose it.  Could you try
> > putting debug.mpsafenet=0 in /boot/loader.conf and reboot to confirm that
> > this is what's going on?
> 
> The de(4) driver is a bit of a mess as regards locking.  I had a look at
> this back in June/July but no longer have the hardware.  It would
> probably be best to bring it under IFF_NEEDSGIANT. 

It is under IFF_NEEDSGIANT, and the interrupt handler is not INTR_MPSAFE.
There-in lies the problem: other non-MPSAFE drivers operate fine under
IFF_NEEDSGIANT.  This suggests that the race in if_de already existed
under Giant but that we've gotten a lot better at triggering it by taking
other pieces of the stack out from under Giant.  For example, it could be
that it handles the insertion of new mbufs into its ifq poorly, or tht it
handles the calling of if_start after it's already drained the packets
from the ifq poorly.  I hope to have some more time to diagnose it today.
One observation that Matthew Dodd made is that it seems to use IFF_OACTIVE
in more extensive ways than most drivers.  I did try having John remove
the IFF_OACTIVE test from if_handoff() to see if that was the race, but
that didn't appear to help.

Robert N M Watson             FreeBSD Core Team, TrustedBSD Projects
robert_at_fledge.watson.org      Principal Research Scientist, McAfee Research
Received on Thu Oct 14 2004 - 06:46:44 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:17 UTC