Netdev List
 help / color / mirror / Atom feed
From: Gerrit Renker <gerrit@erg.abdn.ac.uk>
To: acme@redhat.com
Cc: dccp@vger.kernel.org, netdev@vger.kernel.org,
	Gerrit Renker <gerrit@erg.abdn.ac.uk>
Subject: [PATCH 01/14] [CCID2]: Ack Vectors can happen on most packets
Date: Wed, 19 Dec 2007 14:25:42 +0000	[thread overview]
Message-ID: <1198074355-18842-2-git-send-email-gerrit@erg.abdn.ac.uk> (raw)
In-Reply-To: <1198074355-18842-1-git-send-email-gerrit@erg.abdn.ac.uk>

CCID2 feedback only considers Ack/DataAck packets, but Ack Vectors can appear
on other packets, too. In RFC 4340, 11.4 the only restriction is that they must
not appear on Data or Request packets.

A possible case is for instance a Sync packet used for feature-negotiation
(as used e.g in  section 6.6.1 of RFC 4340). In this case the host must answer
with a SyncAck (7.5.4). Now, if the Sync packet carried an Ack Vector then
the SyncAck acknowledges the receipt of that Ack Vector (thus changing the
Acknowledgment Window, cf. 11.4.2); but the current code would not allow to
parse the received Ack Vector.

The fix is in parsing Ack Vectors on all packet types which are allowed to
carry an Ack Vector.

Signed-off-by: Gerrit Renker <gerrit@erg.abdn.ac.uk>
---
 net/dccp/ccids/ccid2.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

--- a/net/dccp/ccids/ccid2.c
+++ b/net/dccp/ccids/ccid2.c
@@ -549,13 +549,8 @@ static void ccid2_hc_tx_packet_recv(struct sock *sk, struct sk_buff *skb)
 	if (hctx->ccid2hctx_seqh == hctx->ccid2hctx_seqt)
 		return;
 
-	switch (DCCP_SKB_CB(skb)->dccpd_type) {
-	case DCCP_PKT_ACK:
-	case DCCP_PKT_DATAACK:
-		break;
-	default:
+	if (dccp_packet_without_ack(skb))
 		return;
-	}
 
 	ackno = DCCP_SKB_CB(skb)->dccpd_ack_seq;
 	if (after48(ackno, hctx->ccid2hctx_high_ack))
-- 
1.5.3.GIT


  reply	other threads:[~2007-12-19 14:27 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-19 14:25 [DCCP] [RFC] [Patch 0/14]: Ack Vector implementation + fixes Gerrit Renker
2007-12-19 14:25 ` Gerrit Renker [this message]
2007-12-19 14:25   ` [PATCH 02/14] [ACKVEC]: Update Ack Vector fields Gerrit Renker
2007-12-19 14:25     ` [PATCH 03/14] [ACKVEC]: Use Elapsed Time separately Gerrit Renker
2007-12-19 14:25       ` [PATCH 04/14] [ACKVEC]: Inlines for run length and state Gerrit Renker
2007-12-19 14:25         ` [PATCH 05/14] [ACKVEC]: Smaller allocation/deallocation routines Gerrit Renker
2007-12-19 14:25           ` [PATCH 06/14] [ACKVEC]: Simplify adding Ack Vector records, split option-specific code Gerrit Renker
2007-12-19 14:25             ` [PATCH 07/14] [ACKVEC]: Unnecessary to parse Ack Vectors when clearing HC-receiver state Gerrit Renker
2007-12-19 14:25               ` [PATCH 08/14] [ACKVEC]: Use enum to enumerate Ack Vector states Gerrit Renker
2007-12-19 14:25                 ` [PATCH 09/14] [ACKVEC]: Support for circular Ack Vector buffer with overflow handling Gerrit Renker
2007-12-19 14:25                   ` [PATCH 10/14] [ACKVEC]: Determine buffer length dynamically Gerrit Renker
2007-12-19 14:25                     ` [PATCH 11/14] [ACKVEC]: Implement algorithm to update buffer state Gerrit Renker
2007-12-19 14:25                       ` [PATCH 12/14] [ACKVEC]: Update Ack Vector input routine Gerrit Renker
2007-12-19 14:25                         ` [PATCH 13/14] [ACKVEC]: Aggregate Ack-Vector related processing into single function Gerrit Renker
2007-12-19 14:25                           ` [PATCH 14/14] [ACKVEC]: Remove old infrastructure Gerrit Renker

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=1198074355-18842-2-git-send-email-gerrit@erg.abdn.ac.uk \
    --to=gerrit@erg.abdn.ac.uk \
    --cc=acme@redhat.com \
    --cc=dccp@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    /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