lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20140317142356.GA26584@breakpoint.cc>
Date:	Mon, 17 Mar 2014 15:23:56 +0100
From:	Florian Westphal <fw@...len.de>
To:	Eric Dumazet <eric.dumazet@...il.com>
Cc:	Pablo Neira Ayuso <pablo@...filter.org>,
	netfilter-devel@...r.kernel.org, davem@...emloft.net,
	netdev@...r.kernel.org
Subject: Re: [PATCH 36/38] netfilter: connlimit: use keyed locks

Eric Dumazet <eric.dumazet@...il.com> wrote:
> On Mon, 2014-03-17 at 13:42 +0100, Pablo Neira Ayuso wrote:
> > From: Florian Westphal <fw@...len.de>
> > 
> > connlimit currently suffers from spinlock contention, example for
> > 4-core system with rps enabled:
> 
> > +#define CONNLIMIT_SLOTS	256
> > +#define CONNLIMIT_LOCK_SLOTS	32
> 
> 32 spinlocks use 2 cache lines (assuming 4 bytes per spinlock, and 64
> bytes cache lines)
> 
> So I guess this probably should be increased to have less false sharing.

True, Jesper pointed out the same thing to me.

> I believe this hash table of spinlocks could be global, not in each
> struct xt_connlimit_data.

Good point.  Indeed, this can be global.  I did not increase it
since more locks than tree slots is illegal (need exclusive access to
each rtree at this time). I guess we could align it or increase number
of lock and rbtree slots (after moving lock slots out of connlimit
data).

Thanks for the heads-up Eric, I'll see about addressing this later this
week if noone beats me to it.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ