Re: carp patch - will this ever be in releng_6?

2007-06-06 Thread Gleb Smirnoff
On Sat, May 19, 2007 at 04:35:49PM +0300, Stefan Lambrev wrote:
S>  Bruce M. Simpson wrote:
S> > Stefan Lambrev wrote:
S> >>
S> >> Are there any chances for this: 
S> >> 
http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/netinet/ip_carp.c.diff?r1=1.46;r2=1.47
S> >> to be MFCed to RELENG_6 before 6.3-release ?
S> >>
S> >> It fixes quite annoying bug - destroying carpX (when having at least 2 
S> >> carp interfaces) will panic immediately.
S> >> This bugfix is from 3+ months ago.
S> >>
S> > Sadly it is unlikely the failure condition you describe will be fixed in 
S> > -STABLE, as resolving it requires far more work to be merged than the link 
S> > to the diff you post above.
S>  The attached patch worked for me - it is based on the posted URL.
S>  At least I didn't notice bad effects and it fixes the bug.

Bruce misinformes you ;)

I've just merged the patch. Thanks for reminder.

-- 
Totus tuus, Glebius.
GLEBIUS-RIPN GLEB-RIPE
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: carp patch - will this ever be in releng_6?

2007-05-19 Thread Bruce M. Simpson

Stefan Lambrev wrote:


Are there any chances for this: 
http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/netinet/ip_carp.c.diff?r1=1.46;r2=1.47 


to be MFCed to RELENG_6 before 6.3-release ?

It fixes quite annoying bug - destroying carpX (when having at least 2 
carp interfaces) will panic immediately.

This bugfix is from 3+ months ago.



Sadly it is unlikely the failure condition you describe will be fixed in 
-STABLE, as resolving it requires far more work to be merged than the 
link to the diff you post above.


Regards,
BMS
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: carp patch - will this ever be in releng_6?

2007-05-19 Thread Stefan Lambrev

Hi,

Bruce M. Simpson wrote:

Stefan Lambrev wrote:


Are there any chances for this: 
http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/netinet/ip_carp.c.diff?r1=1.46;r2=1.47 


to be MFCed to RELENG_6 before 6.3-release ?

It fixes quite annoying bug - destroying carpX (when having at least 
2 carp interfaces) will panic immediately.

This bugfix is from 3+ months ago.

Sadly it is unlikely the failure condition you describe will be fixed 
in -STABLE, as resolving it requires far more work to be merged than 
the link to the diff you post above.

The attached patch worked for me - it is based on the posted URL.
At least I didn't notice bad effects and it fixes the bug.

--

Best Wishes,
Stefan Lambrev
ICQ# 24134177

--- src/sys/netinet/ip_carp.c.orig  Thu Feb  1 18:53:55 2007
+++ src/sys/netinet/ip_carp.c   Tue Feb  6 18:41:24 2007
@@ -191,7 +191,7 @@
 static voidcarp_input_c(struct mbuf *, struct carp_header *, sa_family_t);
 static int carp_clone_create(struct if_clone *, int);
 static voidcarp_clone_destroy(struct ifnet *);
-static voidcarpdetach(struct carp_softc *);
+static voidcarpdetach(struct carp_softc *, int);
 static int carp_prepare_ad(struct mbuf *, struct carp_softc *,
struct carp_header *);
 static voidcarp_send_ad_all(void);
@@ -406,9 +406,7 @@
 
if (sc->sc_carpdev)
CARP_SCLOCK(sc);
-   carpdetach(sc); 
-   if (sc->sc_carpdev)
-   CARP_SCUNLOCK(sc);
+   carpdetach(sc, 1);  /* Returns unlocked. */
 
mtx_lock(&carp_mtx);
LIST_REMOVE(sc, sc_next);
@@ -420,7 +418,7 @@
 }
 
 static void
-carpdetach(struct carp_softc *sc)
+carpdetach(struct carp_softc *sc, int unlock)  
 {
struct carp_if *cif;
 
@@ -450,9 +448,10 @@
sc->sc_carpdev->if_carp = NULL;
CARP_LOCK_DESTROY(cif);
FREE(cif, M_IFADDR);
-   }
+   } else if (unlock)
+   CARP_UNLOCK(cif);
+   sc->sc_carpdev = NULL;
}
-sc->sc_carpdev = NULL;
 }
 
 /* Detach an interface from the carp. */
@@ -471,7 +470,7 @@
CARP_LOCK(cif);
for (sc = TAILQ_FIRST(&cif->vhif_vrs); sc; sc = nextsc) {
nextsc = TAILQ_NEXT(sc, sc_list);
-   carpdetach(sc);
+   carpdetach(sc, 0);
}
 }
 
___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"

carp patch - will this ever be in releng_6?

2007-05-19 Thread Stefan Lambrev

Hi,

Are there any chances for this: 
http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/netinet/ip_carp.c.diff?r1=1.46;r2=1.47

to be MFCed to RELENG_6 before 6.3-release ?

It fixes quite annoying bug - destroying carpX (when having at least 2 
carp interfaces) will panic immediately.

This bugfix is from 3+ months ago.

--

Best Wishes,
Stefan Lambrev
ICQ# 24134177

___
freebsd-stable@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "[EMAIL PROTECTED]"