From owner-freebsd-stable@FreeBSD.ORG Wed Mar 28 22:30:46 2007 Return-Path: X-Original-To: freebsd-stable@freebsd.org Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id CF46A16A400 for ; Wed, 28 Mar 2007 22:30:46 +0000 (UTC) (envelope-from jdc@koitsu.dyndns.org) Received: from sccrmhc12.comcast.net (sccrmhc12.comcast.net [204.127.200.82]) by mx1.freebsd.org (Postfix) with ESMTP id 8640413C4B8 for ; Wed, 28 Mar 2007 22:30:46 +0000 (UTC) (envelope-from jdc@koitsu.dyndns.org) Received: from icarus.home.lan (c-71-198-0-135.hsd1.ca.comcast.net[71.198.0.135]) by comcast.net (sccrmhc12) with ESMTP id <2007032822304501200t98pue>; Wed, 28 Mar 2007 22:30:45 +0000 Received: by icarus.home.lan (Postfix, from userid 1000) id 42AB61FA03D; Wed, 28 Mar 2007 15:30:45 -0700 (PDT) Date: Wed, 28 Mar 2007 15:30:45 -0700 From: Jeremy Chadwick To: Andrew Thompson Message-ID: <20070328223045.GA84408@icarus.home.lan> Mail-Followup-To: Andrew Thompson , freebsd-stable@freebsd.org References: <20070328033327.GA65649@icarus.home.lan> <20070328213709.GA80375@heff.fud.org.nz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20070328213709.GA80375@heff.fud.org.nz> User-Agent: Mutt/1.5.13 (2006-08-11) Cc: freebsd-stable@freebsd.org Subject: Re: em(4) losing link when if_bridge(4) addm/deletem are used X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 28 Mar 2007 22:30:46 -0000 On Thu, Mar 29, 2007 at 09:37:09AM +1200, Andrew Thompson wrote: > On Tue, Mar 27, 2007 at 08:33:27PM -0700, Jeremy Chadwick wrote: > > In the midst of the madness, I found that when doing either of the > > following commands... > > > > ifconfig bridge0 addm em1 > > ifconfig bridge0 deletem em1 > > > > ...I see the entire em1 interface completely reset, bringing down link, > > then up again shortly after. The logs on my switch also confirm this. > > > > For sake of comparison, the bge(4) driver does not behave this way. > > > > I am aware that if_bridge(4) enables promiscuous mode on whatever > > interface is being added, ditto with -promisc on deletem. However, this > > does not appear to be the cause of the problem, because I can do > > "ifconfig em1 promisc" and "ifconfig em1 -promisc" without loss of link. > > The only other thing the bridge does to the interface when removing it > is to reinstate IFCAP_TXCSUM, which is disabled when the interface is > bridged. If you manually toggle this with ifconfig do you get the same > result? Bingo. medusa# ifconfig em1 -txcsum medusa# ifconfig em1 em1: flags=8843 mtu 1500 options=8 inet 10.0.0.2 netmask 0xffffff00 broadcast 10.0.0.255 ether 00:30:48:71:60:6b media: Ethernet autoselect status: no carrier medusa# grep em1 /var/log/messages Mar 28 15:29:34 medusa kernel: em1: link state changed to DOWN Mar 28 15:29:36 medusa kernel: em1: link state changed to UP -- | Jeremy Chadwick jdc at parodius.com | | Parodius Networking http://www.parodius.com/ | | UNIX Systems Administrator Mountain View, CA, USA | | Making life hard for others since 1977. PGP: 4BD6C0CB |