netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: jon.maloy@ericsson.com
Cc: netdev@vger.kernel.org, paul.gortmaker@windriver.com,
	erik.hugne@ericsson.com, ying.xue@windriver.com,
	maloy@donjonn.com, tipc-discussion@lists.sourceforge.net
Subject: Re: [PATCH net 1/1] tipc: correctly unlink packets from deferred packet queue
Date: Tue, 07 Jan 2014 16:17:10 -0500 (EST)	[thread overview]
Message-ID: <20140107.161710.1111837486038919201.davem@davemloft.net> (raw)
In-Reply-To: <1389127896-7428-1-git-send-email-jon.maloy@ericsson.com>

From: Jon Maloy <jon.maloy@ericsson.com>
Date: Tue,  7 Jan 2014 15:51:36 -0500

> From: Erik Hugne <erik.hugne@ericsson.com>
> 
> When we pull a received packet from a link's 'deferred packets' queue
> for processing, its 'next' pointer is not cleared, and still refers to
> the next packet in that queue, if any. This is incorrect, but caused
> no harm before commit 40ba3cdf542a469aaa9083fa041656e59b109b90 ("tipc:
> message reassembly using fragment chain") was introduced. After that
> commit, it may sometimes lead to the following oops:
 ...
> This happens when the last fragment of a message has passed through the
> the receiving link's 'deferred packets' queue, and at least one other
> packet was added to that queue while it was there. After the fragment
> chain with the complete message has been successfully delivered to the
> receiving socket, it is released. Since 'next' pointer of the last
> fragment in the released chain now is non-NULL, we get the crash shown
> above.
> 
> We fix this by clearing the 'next' pointer of all received packets,
> including those being pulled from the 'deferred' queue, before they
> undergo any further processing.
> 
> Fixes: 40ba3cdf542a4 ("tipc: message reassembly using fragment chain")
> Signed-off-by: Erik Hugne <erik.hugne@ericsson.com>
> Reported-by: Ying Xue <ying.xue@windriver.com>
> Reviewed-by: Paul Gortmaker <paul.gortmaker@windriver.com>
> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com>

Applied and queued up for -stable, thanks.

      reply	other threads:[~2014-01-07 21:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-07 20:51 [PATCH net 1/1] tipc: correctly unlink packets from deferred packet queue Jon Maloy
2014-01-07 21:17 ` David Miller [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20140107.161710.1111837486038919201.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=erik.hugne@ericsson.com \
    --cc=jon.maloy@ericsson.com \
    --cc=maloy@donjonn.com \
    --cc=netdev@vger.kernel.org \
    --cc=paul.gortmaker@windriver.com \
    --cc=tipc-discussion@lists.sourceforge.net \
    --cc=ying.xue@windriver.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).