Date: Sat, 11 Jun 2005 10:01:33 +1200 From: Andrew Thompson <thompsa@freebsd.org> To: Brooks Davis <brooks@one-eyed-alien.net> Cc: current@freebsd.org, net@freebsd.org Subject: Re: HEADSUP: internal network interface changes Message-ID: <20050610220133.GA69748@heff.fud.org.nz> In-Reply-To: <20050610165724.GA17120@odin.ac.hmc.edu> References: <20050609064452.GC1595@odin.ac.hmc.edu> <20050610162600.GA12928@odin.ac.hmc.edu> <20050610165724.GA17120@odin.ac.hmc.edu>
next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Jun 10, 2005 at 09:57:24AM -0700, Brooks Davis wrote: > On Fri, Jun 10, 2005 at 09:26:00AM -0700, Brooks Davis wrote: > > Look out! :-) > > > > This change is incoming sortly (pending final cvs updates). > > I've committed the change bumping __FreeBSD_version. Hopefully the > ride won't be too bumpy. If you have any problems, please report them > on -current as well as to me directly. Most problems should be fairly > simple to fix. I will be checking my e-mail regularly for at least the > next 14 hours. > Im getting a panic with if_bridge, it seems to have been missed from the if_alloc() changes. cheers, Andrew Index: sys/net/if_bridge.c =================================================================== RCS file: /home/ncvs/src/sys/net/if_bridge.c,v retrieving revision 1.6 diff -u -r1.6 if_bridge.c --- sys/net/if_bridge.c 10 Jun 2005 16:49:18 -0000 1.6 +++ sys/net/if_bridge.c 10 Jun 2005 21:55:30 -0000 @@ -422,7 +422,11 @@ sc = malloc(sizeof(*sc), M_DEVBUF, M_WAITOK|M_ZERO); BRIDGE_LOCK_INIT(sc); - ifp = sc->sc_ifp; + ifp = sc->sc_ifp = if_alloc(IFT_BRIDGE); + if (ifp == NULL) { + free(sc, M_DEVBUF); + return (ENOSPC); + } sc->sc_brtmax = BRIDGE_RTABLE_MAX; sc->sc_brttimeout = BRIDGE_RTABLE_TIMEOUT; @@ -447,7 +451,6 @@ ifp->if_output = bridge_output; ifp->if_start = bridge_start; ifp->if_init = bridge_init; - ifp->if_type = IFT_BRIDGE; IFQ_SET_MAXLEN(&ifp->if_snd, ifqmaxlen); ifp->if_snd.ifq_drv_maxlen = ifqmaxlen; IFQ_SET_READY(&ifp->if_snd); @@ -499,6 +502,7 @@ mtx_unlock(&bridge_list_mtx); ether_ifdetach(ifp); + if_free(ifp); /* Tear down the routing table. */ bridge_rtable_fini(sc);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20050610220133.GA69748>