The following reply was made to PR kern/164696; it has been noted by GNATS.
From: Gleb Smirnoff <gleb...@freebsd.org> To: Nikos Vassiliadis <nv...@gmx.com> Cc: freebsd-gnats-sub...@freebsd.org Subject: Re: kern/164696: VIMAGE + carp panics the kernel Date: Mon, 6 Feb 2012 15:47:41 +0400 --TakKZr9L6Hm6aLOc Content-Type: text/plain; charset=koi8-r Content-Disposition: inline Hi, Nikos! On Wed, Feb 01, 2012 at 10:40:35PM +0000, Nikos Vassiliadis wrote: N> >Description: N> Trying to use a carp interface in a VIMAGE enabled kernel, panics the kernel. Can you please test another patch, that is attached? -- Totus tuus, Glebius. --TakKZr9L6Hm6aLOc Content-Type: text/x-diff; charset=koi8-r Content-Disposition: attachment; filename="164696.diff" Index: ip_carp.c =================================================================== --- ip_carp.c (revision 231067) +++ ip_carp.c (working copy) @@ -707,19 +707,24 @@ LIST_FOREACH(sc, &carp_list, sc_next) if (sc->sc_state == MASTER) { CARP_LOCK(sc); + CURVNET_SET(sc->sc_carpdev->if_vnet); carp_send_ad_locked(sc); + CURVNET_RESTORE(); CARP_UNLOCK(sc); } mtx_unlock(&carp_mtx); } +/* Send a periodic advertisement, executed in callout context. */ static void carp_send_ad(void *v) { struct carp_softc *sc = v; CARP_LOCK_ASSERT(sc); + CURVNET_SET(sc->sc_carpdev->if_vnet); carp_send_ad_locked(sc); + CURVNET_RESTORE(); CARP_UNLOCK(sc); } @@ -1090,6 +1095,7 @@ return (0); } +/* Master down timeout event, executed in callout context. */ static void carp_master_down(void *v) { @@ -1097,12 +1103,14 @@ CARP_LOCK_ASSERT(sc); + CURVNET_SET(sc->sc_carpdev->if_vnet); if (sc->sc_state == BACKUP) { CARP_LOG("VHID %u@%s: BACKUP -> MASTER (master down)\n", sc->sc_vhid, sc->sc_carpdev->if_xname); carp_master_down_locked(sc); } + CURVNET_RESTORE(); CARP_UNLOCK(sc); } --TakKZr9L6Hm6aLOc-- _______________________________________________ freebsd-net@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-net To unsubscribe, send any mail to "freebsd-net-unsubscr...@freebsd.org"