netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Re: [PATCH] netfilter: Force fake conntrack entry to be at least 8 bytes aligned
       [not found] ` <20170311091222.GA24201@breakpoint.cc>
@ 2017-03-13 12:33   ` Pablo Neira Ayuso
  2017-03-13 12:36     ` Pablo Neira Ayuso
  0 siblings, 1 reply; 3+ messages in thread
From: Pablo Neira Ayuso @ 2017-03-13 12:33 UTC (permalink / raw)
  To: Florian Westphal
  Cc: Steven Rostedt (VMware), LKML, netdev, David Miller,
	Jozsef Kadlecsik, coreteam, netfilter-devel

On Sat, Mar 11, 2017 at 10:12:22AM +0100, Florian Westphal wrote:
> Steven Rostedt (VMware) <rostedt@goodmis.org> wrote:
> > Since the nfct and nfctinfo have been combined, the nf_conn structure
> > must be at least 8 bytes aligned, as the 3 LSB bits are used for the
> > nfctinfo. But there's a fake nf_conn structure to denote untracked
> > connections, which is created by a PER_CPU construct. This does not
> > guarantee that it will be 8 bytes aligned and can break the logic in
> > determining the correct nfctinfo.
> > 
> > I triggered this on a 32bit machine with the following error:
> [..]
> 
> Ugh.  Originally I had planned to also submit followup changes
> to get rid of the untracked objects but that part got delayed.
> 
> > By using DEFINE/DECLARE_PER_CPU_ALIGNED we can enforce at least 8 byte
> > alignment as all cache line sizes are at least 8 bytes or more.
> 
> Thanks for fixing this!
> 
> Acked-by: Florian Westphal <fw@strlen.de>

Applied, thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] netfilter: Force fake conntrack entry to be at least 8 bytes aligned
  2017-03-13 12:33   ` [PATCH] netfilter: Force fake conntrack entry to be at least 8 bytes aligned Pablo Neira Ayuso
@ 2017-03-13 12:36     ` Pablo Neira Ayuso
  2017-03-13 12:41       ` Florian Westphal
  0 siblings, 1 reply; 3+ messages in thread
From: Pablo Neira Ayuso @ 2017-03-13 12:36 UTC (permalink / raw)
  To: Florian Westphal; +Cc: netfilter-devel

On Mon, Mar 13, 2017 at 01:33:32PM +0100, Pablo Neira Ayuso wrote:
> On Sat, Mar 11, 2017 at 10:12:22AM +0100, Florian Westphal wrote:
> > Steven Rostedt (VMware) <rostedt@goodmis.org> wrote:
> > > Since the nfct and nfctinfo have been combined, the nf_conn structure
> > > must be at least 8 bytes aligned, as the 3 LSB bits are used for the
> > > nfctinfo. But there's a fake nf_conn structure to denote untracked
> > > connections, which is created by a PER_CPU construct. This does not
> > > guarantee that it will be 8 bytes aligned and can break the logic in
> > > determining the correct nfctinfo.
> > > 
> > > I triggered this on a 32bit machine with the following error:
> > [..]
> > 
> > Ugh.  Originally I had planned to also submit followup changes
> > to get rid of the untracked objects but that part got delayed.
> > 
> > > By using DEFINE/DECLARE_PER_CPU_ALIGNED we can enforce at least 8 byte
> > > alignment as all cache line sizes are at least 8 bytes or more.
> > 
> > Thanks for fixing this!
> > 
> > Acked-by: Florian Westphal <fw@strlen.de>
> 
> Applied, thanks.

@Florian: This is clashing with your nf-next patches to kill the fake
conntrack. Would you mind if you resubmit these once this fix shows up
in the nf-next.git tree. I'll try to expedite this.

Thanks.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] netfilter: Force fake conntrack entry to be at least 8 bytes aligned
  2017-03-13 12:36     ` Pablo Neira Ayuso
@ 2017-03-13 12:41       ` Florian Westphal
  0 siblings, 0 replies; 3+ messages in thread
From: Florian Westphal @ 2017-03-13 12:41 UTC (permalink / raw)
  To: Pablo Neira Ayuso; +Cc: Florian Westphal, netfilter-devel

Pablo Neira Ayuso <pablo@netfilter.org> wrote:
> @Florian: This is clashing with your nf-next patches to kill the fake
> conntrack. Would you mind if you resubmit these once this fix shows up
> in the nf-next.git tree.

no problem, I'll respin once its there.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-03-13 12:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <20170311002526.1d21e750@gandalf.local.home>
     [not found] ` <20170311091222.GA24201@breakpoint.cc>
2017-03-13 12:33   ` [PATCH] netfilter: Force fake conntrack entry to be at least 8 bytes aligned Pablo Neira Ayuso
2017-03-13 12:36     ` Pablo Neira Ayuso
2017-03-13 12:41       ` Florian Westphal

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).