* [PATCH nf-next] netfilter: conntrack: align nf_conn on cacheline boundary
@ 2016-06-10 20:25 Florian Westphal
2016-06-23 17:38 ` Pablo Neira Ayuso
0 siblings, 1 reply; 2+ messages in thread
From: Florian Westphal @ 2016-06-10 20:25 UTC (permalink / raw)
To: netfilter-devel; +Cc: Florian Westphal
increases struct size by 32 bytes (288 -> 320), but it is the right thing,
else any attempt to (re-)arrange nf_conn members by cacheline won't work.
Signed-off-by: Florian Westphal <fw@strlen.de>
---
gives checkpatch warn due to line > 80 lines but I don't want to
add a line-break after | just for checkpatch...
diff --git a/net/netfilter/nf_conntrack_core.c b/net/netfilter/nf_conntrack_core.c
index c74dac7..a459176 100644
--- a/net/netfilter/nf_conntrack_core.c
+++ b/net/netfilter/nf_conntrack_core.c
@@ -1711,7 +1711,7 @@ int nf_conntrack_init_start(void)
nf_conntrack_cachep = kmem_cache_create("nf_conntrack",
sizeof(struct nf_conn), 0,
- SLAB_DESTROY_BY_RCU, NULL);
+ SLAB_DESTROY_BY_RCU | SLAB_HWCACHE_ALIGN, NULL);
if (!nf_conntrack_cachep)
goto err_cachep;
--
2.7.3
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH nf-next] netfilter: conntrack: align nf_conn on cacheline boundary
2016-06-10 20:25 [PATCH nf-next] netfilter: conntrack: align nf_conn on cacheline boundary Florian Westphal
@ 2016-06-23 17:38 ` Pablo Neira Ayuso
0 siblings, 0 replies; 2+ messages in thread
From: Pablo Neira Ayuso @ 2016-06-23 17:38 UTC (permalink / raw)
To: Florian Westphal; +Cc: netfilter-devel
On Fri, Jun 10, 2016 at 10:25:22PM +0200, Florian Westphal wrote:
> increases struct size by 32 bytes (288 -> 320), but it is the right thing,
> else any attempt to (re-)arrange nf_conn members by cacheline won't work.
Applied, thanks Florian.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-06-23 17:38 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-06-10 20:25 [PATCH nf-next] netfilter: conntrack: align nf_conn on cacheline boundary Florian Westphal
2016-06-23 17:38 ` Pablo Neira Ayuso
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).