From patchwork Thu Mar 12 19:49:19 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vlad Yasevich X-Patchwork-Id: 24357 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id DCC3EDE0C3 for ; Fri, 13 Mar 2009 06:49:51 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755836AbZCLTte (ORCPT ); Thu, 12 Mar 2009 15:49:34 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755738AbZCLTtb (ORCPT ); Thu, 12 Mar 2009 15:49:31 -0400 Received: from g5t0008.atlanta.hp.com ([15.192.0.45]:45299 "EHLO g5t0008.atlanta.hp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755589AbZCLTt1 (ORCPT ); Thu, 12 Mar 2009 15:49:27 -0400 Received: from smtp1.fc.hp.com (smtp1.fc.hp.com [15.15.136.127]) by g5t0008.atlanta.hp.com (Postfix) with ESMTP id 14FF3242CF; Thu, 12 Mar 2009 19:49:26 +0000 (UTC) Received: from localhost.localdomain (squirrel.fc.hp.com [15.11.146.57]) by smtp1.fc.hp.com (Postfix) with ESMTP id D0DA124CA5D; Thu, 12 Mar 2009 19:21:22 +0000 (UTC) From: Vlad Yasevich To: davem@davemloft.net Cc: linux-sctp@vger.kernel.org, netdev@vger.kernel.org, Wei Yongjun , Vlad Yasevich Subject: [PATCH net-next 3/4] sctp: fix to send FORWARD-TSN chunk only if peer has such capable Date: Thu, 12 Mar 2009 15:49:19 -0400 Message-Id: <1236887360-1904-4-git-send-email-vladislav.yasevich@hp.com> X-Mailer: git-send-email 1.5.4.3 In-Reply-To: <1236887360-1904-1-git-send-email-vladislav.yasevich@hp.com> References: <1236887360-1904-1-git-send-email-vladislav.yasevich@hp.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org From: Wei Yongjun RFC3758 Section 3.3.1. Sending Forward-TSN-Supported param in INIT Note that if the endpoint chooses NOT to include the parameter, then at no time during the life of the association can it send or process a FORWARD TSN. If peer does not support PR-SCTP capable, don't send FORWARD-TSN chunk to peer. Signed-off-by: Wei Yongjun Signed-off-by: Vlad Yasevich --- net/sctp/outqueue.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/net/sctp/outqueue.c b/net/sctp/outqueue.c index a367d15..d765fc5 100644 --- a/net/sctp/outqueue.c +++ b/net/sctp/outqueue.c @@ -1758,6 +1758,9 @@ static void sctp_generate_fwdtsn(struct sctp_outq *q, __u32 ctsn) struct sctp_chunk *chunk; struct list_head *lchunk, *temp; + if (!asoc->peer.prsctp_capable) + return; + /* PR-SCTP C1) Let SackCumAck be the Cumulative TSN ACK carried in the * received SACK. *