Date: Tue, 20 Mar 2012 14:53:52 -0400 From: John Baldwin <jhb@freebsd.org> To: Sergey Kandaurov <pluknet@freebsd.org> Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-8@freebsd.org Subject: Re: svn commit: r233199 - in stable/8/sys: i386/conf netinet6 Message-ID: <201203201453.52982.jhb@freebsd.org> In-Reply-To: <CAE-mSOL=qEHEi4vN18JuhfoihsjaLDOrnpbaNoBdGKhZB9FLFw@mail.gmail.com> References: <201203192015.q2JKFItl084480@svn.freebsd.org> <CAE-mSOL=qEHEi4vN18JuhfoihsjaLDOrnpbaNoBdGKhZB9FLFw@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tuesday, March 20, 2012 5:02:48 am Sergey Kandaurov wrote: > On 20 March 2012 00:15, John Baldwin <jhb@freebsd.org> wrote: > > Author: jhb > > Date: Mon Mar 19 20:15:18 2012 > > New Revision: 233199 > > URL: http://svn.freebsd.org/changeset/base/233199 > > > > Log: > > MFC 225096: > > Fix if_addr_mtx recursion in mld6. > > Ehh.. Thank you for doing this. > As I mentioned earlier I could not reproduce this problem myself > in RELENG_8, that's why it was not MFCed so far... To be honest, my main movitation was to remove a merge conflict in my subsequent MFC of the IF_ADDR locking changes. I could have patched the locking in the old mld6.c, but when I reviewed your diff, I figured it would be better to merge it first instead. > > > > mld_set_version() is called only from mld_v1_input_query() and > > mld_v2_input_query() both holding the if_addr_mtx lock, and then calling > > into mld_v2_cancel_link_timers() acquires it the second time, which results > > in mtx recursion. To avoid that, delay if_addr_mtx acquisition until after > > mld_set_version() is called; while here, further reduce locking scope > > to protect only the needed pieces: if_multiaddrs, in6m_lookup_locked(). > > [...] > > -- > wbr, > pluknet > -- John Baldwin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201203201453.52982.jhb>