From: David Howells <dhowells@redhat.com>
To: netdev@vger.kernel.org
Cc: dhowells@redhat.com, tim@electronghost.co.uk,
linux-afs@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: [PATCH 2/8] af_rxrpc: Prevent RxRPC peers from ABORT-storming one another [ver #2]
Date: Thu, 06 Mar 2014 12:46:29 +0000 [thread overview]
Message-ID: <20140306124629.16645.63784.stgit@warthog.procyon.org.uk> (raw)
In-Reply-To: <20140306124614.16645.50744.stgit@warthog.procyon.org.uk>
From: Tim Smith <tim@electronghost.co.uk>
When an ABORT is sent, aborting a connection, the sender quite reasonably
forgets about the connection. If another frame is received, another ABORT
will be sent. When the receiver gets it, it no longer applies to an extant
connection, so an ABORT is sent, and so on...
Prevent this by never sending a rejection for an ABORT packet.
Signed-off-by: Tim Smith <tim@electronghost.co.uk>
Signed-off-by: David Howells <dhowells@redhat.com>
---
net/rxrpc/ar-input.c | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/net/rxrpc/ar-input.c b/net/rxrpc/ar-input.c
index 529572f18d1f..eb7e16276cc1 100644
--- a/net/rxrpc/ar-input.c
+++ b/net/rxrpc/ar-input.c
@@ -606,8 +606,10 @@ dead_call:
}
_debug("dead call");
- skb->priority = RX_CALL_DEAD;
- rxrpc_reject_packet(conn->trans->local, skb);
+ if (sp->hdr.type != RXRPC_PACKET_TYPE_ABORT) {
+ skb->priority = RX_CALL_DEAD;
+ rxrpc_reject_packet(conn->trans->local, skb);
+ }
goto done;
/* resend last packet of a completed call
@@ -790,8 +792,10 @@ cant_route_call:
skb->priority = RX_CALL_DEAD;
}
- _debug("reject");
- rxrpc_reject_packet(local, skb);
+ if (sp->hdr.type != RXRPC_PACKET_TYPE_ABORT) {
+ _debug("reject type %d",sp->hdr.type);
+ rxrpc_reject_packet(local, skb);
+ }
rxrpc_put_local(local);
_leave(" [no call]");
return;
next prev parent reply other threads:[~2014-03-06 12:46 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-06 12:46 [PATCH 0/8] AF_RXRPC fixes and development " David Howells
2014-03-06 12:46 ` [PATCH 1/8] af_rxrpc: Remove incorrect checksum calculation from rxrpc_recvmsg() " David Howells
2014-03-06 12:46 ` David Howells [this message]
2014-03-06 12:46 ` [PATCH 3/8] af_rxrpc: Fix UDP MTU calculation from ICMP_FRAG_NEEDED " David Howells
2014-03-06 12:46 ` [PATCH 4/8] af_rxrpc: Add sysctls for configuring RxRPC parameters " David Howells
2014-03-06 12:46 ` [PATCH 5/8] af_rxrpc: Improve ACK production " David Howells
2014-03-06 12:46 ` [PATCH 6/8] af_rxrpc: Expose more RxRPC parameters via sysctls " David Howells
2014-03-06 12:47 ` [PATCH 7/8] af_rxrpc: Request an ACK for every alternate DATA packet " David Howells
2014-03-06 12:47 ` [PATCH 8/8] af_rxrpc: Keep rxrpc_call pointers in a hashtable " David Howells
2014-03-06 19:37 ` [PATCH 0/8] AF_RXRPC fixes and development " David Miller
2014-03-06 22:15 ` David Howells
2014-03-06 22:16 ` David Miller
2014-03-06 22:31 ` David Howells
2014-03-07 21:12 ` David Miller
2014-03-06 22:32 ` David Howells
2014-03-06 22:38 ` David Miller
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=20140306124629.16645.63784.stgit@warthog.procyon.org.uk \
--to=dhowells@redhat.com \
--cc=linux-afs@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=tim@electronghost.co.uk \
/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
Powered by JetHome