aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVlad Yasevich <vladislav.yasevich@hp.com>2008-01-07 03:28:16 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-09 02:30:04 -0500
commit036b579b1146f52c51398f1ab663cf659094107d (patch)
tree21491019a0b98a24e3e1ea356778afd0df46c497
parent6df9cfc1ad45839e2a11330ab354330c6128cb73 (diff)
[SCTP]: Add back the code that accounted for FORWARD_TSN parameter in INIT.
Some recent changes completely removed accounting for the FORWARD_TSN parameter length in the INIT and INIT-ACK chunk. This is wrong and should be restored. Signed-off-by: Vlad Yasevich <vladislav.yasevich@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/sctp/sm_make_chunk.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/net/sctp/sm_make_chunk.c b/net/sctp/sm_make_chunk.c
index ed7c9e30ebc9..3cc629d3c9ff 100644
--- a/net/sctp/sm_make_chunk.c
+++ b/net/sctp/sm_make_chunk.c
@@ -210,6 +210,9 @@ struct sctp_chunk *sctp_make_init(const struct sctp_association *asoc,
210 chunksize = sizeof(init) + addrs_len + SCTP_SAT_LEN(num_types); 210 chunksize = sizeof(init) + addrs_len + SCTP_SAT_LEN(num_types);
211 chunksize += sizeof(ecap_param); 211 chunksize += sizeof(ecap_param);
212 212
213 if (sctp_prsctp_enable)
214 chunksize += sizeof(prsctp_param);
215
213 /* ADDIP: Section 4.2.7: 216 /* ADDIP: Section 4.2.7:
214 * An implementation supporting this extension [ADDIP] MUST list 217 * An implementation supporting this extension [ADDIP] MUST list
215 * the ASCONF,the ASCONF-ACK, and the AUTH chunks in its INIT and 218 * the ASCONF,the ASCONF-ACK, and the AUTH chunks in its INIT and
@@ -369,6 +372,9 @@ struct sctp_chunk *sctp_make_init_ack(const struct sctp_association *asoc,
369 if (asoc->peer.ecn_capable) 372 if (asoc->peer.ecn_capable)
370 chunksize += sizeof(ecap_param); 373 chunksize += sizeof(ecap_param);
371 374
375 if (sctp_prsctp_enable)
376 chunksize += sizeof(prsctp_param);
377
372 if (sctp_addip_enable) { 378 if (sctp_addip_enable) {
373 extensions[num_ext] = SCTP_CID_ASCONF; 379 extensions[num_ext] = SCTP_CID_ASCONF;
374 extensions[num_ext+1] = SCTP_CID_ASCONF_ACK; 380 extensions[num_ext+1] = SCTP_CID_ASCONF_ACK;