Date: Thu, 22 Jan 2015 00:44:45 +0300 From: Gleb Smirnoff <glebius@FreeBSD.org> To: Craig Rodrigues <rodrigc@FreeBSD.org>, Nikos Vassiliadis <nvass@gmx.com> Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r276747 - head/sys/netpfil/pf Message-ID: <20150121214445.GL15484@FreeBSD.org> In-Reply-To: <20150107204631.GG15484@FreeBSD.org> References: <201501060903.t06934qp081875@svn.freebsd.org> <20150107204631.GG15484@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Jan 07, 2015 at 11:46:31PM +0300, Gleb Smirnoff wrote: T> On Tue, Jan 06, 2015 at 09:03:04AM +0000, Craig Rodrigues wrote: T> C> Author: rodrigc T> C> Date: Tue Jan 6 09:03:03 2015 T> C> New Revision: 276747 T> C> URL: https://svnweb.freebsd.org/changeset/base/276747 T> C> T> C> Log: T> C> Instead of creating a purge thread for every vnet, create T> C> a single purge thread and clean up all vnets from this thread. T> C> T> C> PR: 194515 T> C> Differential Revision: D1315 T> C> Submitted by: Nikos Vassiliadis <nvass@gmx.com> T> T> I am not sure that this is a good idea. The core idea of VNETs T> is that they are isolated from each other. If we serialize purging, T> then vnets are strongly affecting each other. T> T> AFAIU, from the PR there is some panic fixed. What is the actual bug T> and why couldn't it be fixed with having per-vnet thread? So, after closer inspection, this commit is a completely messed up. You blindly remove kproc_exit(). What do you think would happen on 'kldunload -f pf'? You removed PF_RULES_RLOCK(). Cool! Now the purging thread doesn't acquire the pf lock. You substitute rw_sleep() with tsleep(). And the latter requires Giant to be held. If you tried your change with INVARIANTS, it would panic immediately. -- Totus tuus, Glebius.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20150121214445.GL15484>