From owner-freebsd-net@FreeBSD.ORG Fri May 18 14:27:52 2012 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 34097106564A; Fri, 18 May 2012 14:27:52 +0000 (UTC) (envelope-from jhb@freebsd.org) Received: from bigwig.baldwin.cx (bigknife-pt.tunnel.tserv9.chi1.ipv6.he.net [IPv6:2001:470:1f10:75::2]) by mx1.freebsd.org (Postfix) with ESMTP id 0582D8FC08; Fri, 18 May 2012 14:27:52 +0000 (UTC) Received: from jhbbsd.localnet (unknown [209.249.190.124]) by bigwig.baldwin.cx (Postfix) with ESMTPSA id 6019AB9B0; Fri, 18 May 2012 10:27:51 -0400 (EDT) From: John Baldwin To: freebsd-net@freebsd.org Date: Fri, 18 May 2012 10:27:49 -0400 User-Agent: KMail/1.13.5 (FreeBSD/8.2-CBSD-20110714-p13; KDE/4.5.5; amd64; ; ) References: In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <201205181027.49210.jhb@freebsd.org> X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.7 (bigwig.baldwin.cx); Fri, 18 May 2012 10:27:51 -0400 (EDT) Cc: Robert Watson , gavin@freebsd.org, "Devon H. O'Dell" , bug-followup@freebsd.org Subject: Re: kern/110284: [if_ethersubr] Invalid Assumption in SIOCSIFADDR in ether_ioctl() X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 18 May 2012 14:27:52 -0000 On Wednesday, May 16, 2012 10:37:36 pm Devon H. O'Dell wrote: > 2012/5/16 Devon H. O'Dell : > > Hi Gavin, freebsd-net, > > > > --- if_ethersubr.c 2011-09-22 20:51:37.000000000 -0400 > > +++ /home/dho/if_ethersubr.c 2012-05-16 22:27:17.000000000 -0400 > > @@ -1146,7 +1146,9 @@ > > switch (ifa->ifa_addr->sa_family) { > > #ifdef INET > > case AF_INET: > > - ifp->if_init(ifp->if_softc); /* before arpwhohas */ > > + if (ifp->if_flags & IFF_RUNNING == 0) { > > That's probably ((ifp->if_flags & IFF_RUNNING) == 0). Also, I'm not on > freebsd-net or cc'ed on the PR afaik, so please cc me explicitly on > followups if more information is needed. You mean if_drv_flags and IF_DRV_RUNNING. It's a bit fugly, yes, and the new check would be racey. -- John Baldwin