summaryrefslogtreecommitdiffstats
path: root/sys/netinet/sctp_structs.h
diff options
context:
space:
mode:
authorrrs <rrs@FreeBSD.org>2007-08-27 05:19:48 +0000
committerrrs <rrs@FreeBSD.org>2007-08-27 05:19:48 +0000
commite335457f91efbba1e9ccc24574c0ffc73235bd94 (patch)
tree5c37015ad6945c94641b6d5d3a589608e280afe1 /sys/netinet/sctp_structs.h
parent3eb0fa1342d0b24e14ff06361e7b8a71c4441b06 (diff)
downloadFreeBSD-src-e335457f91efbba1e9ccc24574c0ffc73235bd94.zip
FreeBSD-src-e335457f91efbba1e9ccc24574c0ffc73235bd94.tar.gz
- During shutdown pending, when the last sack came in and
the last message on the send stream was "null" but still there, a state we allow, we could get hung and not clean it up and wait for the shutdown guard timer to clear the association without a graceful close. Fix this so that that we properly clean up. - Added support for Multiple ASCONF per new RFC. We only (so far) accept input of these and cannot yet generate a multi-asconf. - Sysctl'd support for experimental Fast Handover feature. Always disabled unless sysctl or socket option changes to enable. - Error case in add-ip where the peer supports AUTH and ADD-IP but does NOT require AUTH of ASCONF/ASCONF-ACK. We need to ABORT in this case. - According to the Kyoto summit of socket api developers (Solaris, Linux, BSD). We need to have: o non-eeor mode messages be atomic - Fixed o Allow implicit setup of an assoc in 1-2-1 model if using the sctp_**() send calls - Fixed o Get rid of HAVE_XXX declarations - Done o add a sctp_pr_policy in hole in sndrcvinfo structure - Done o add a PR_SCTP_POLICY_VALID type flag - yet to-do in a future patch! - Optimize sctp6 calls to reuse code in sctp_usrreq. Also optimize when we close sending out the data and disabling Nagle. - Change key concatenation order to match the auth RFC - When sending OOTB shutdown_complete always do csum. - Don't send PKT-DROP to a PKT-DROP - For abort chunks just always checksums same for shutdown-complete. - inpcb_free front state had a bug where in queue data could wedge an assoc. We need to just abandon ones in front states (free_assoc). - If a peer sends us a 64k abort, we would try to assemble a response packet which may be larger than 64k. This then would be dropped by IP. Instead make a "minimum" size for us 64k-2k (we want at least 2k for our initack). If we receive such an init discard it early without all the processing. - When we peel off we must increment the tcb ref count to keep it from being freed from underneath us. - handling fwd-tsn had bugs that caused memory overwrites when given faulty data, fixed so can't happen and we also stop at the first bad stream no. - Fixed so comm-up generates the adaption indication. - peeloff did not get the hmac params copied. - fix it so we lock the addr list when doing src-addr selection (in future we need to use a multi-reader/one writer lock here) - During lowlevel output, we could end up with a _l_addr set to null if the iterator is calling the output routine. This means we would possibly crash when we gather the MTU info. Fix so we only do the gather where we have a src address cached. - we need to be sure to set abort flag on conn state when we receive an abort. - peeloff could leak a socket. Moved code so the close will find the socket if the peeloff fails (uipc_syscalls.c) Approved by: re@freebsd.org(Ken Smith)
Diffstat (limited to 'sys/netinet/sctp_structs.h')
-rw-r--r--sys/netinet/sctp_structs.h16
1 files changed, 14 insertions, 2 deletions
diff --git a/sys/netinet/sctp_structs.h b/sys/netinet/sctp_structs.h
index f4480d4..217f5a0 100644
--- a/sys/netinet/sctp_structs.h
+++ b/sys/netinet/sctp_structs.h
@@ -547,6 +547,16 @@ struct sctp_cc_functions {
struct sctp_tcb *stcb, struct sctp_nets *net);
};
+/* used to save ASCONF-ACK chunks for retransmission */
+TAILQ_HEAD(sctp_asconf_ackhead, sctp_asconf_ack);
+struct sctp_asconf_ack {
+ TAILQ_ENTRY(sctp_asconf_ack) next;
+ uint32_t serial_number;
+ struct sctp_nets *last_sent_to;
+ struct mbuf *data;
+ uint16_t len;
+};
+
/*
* Here we have information about each individual association that we track.
* We probably in production would be more dynamic. But for ease of
@@ -622,7 +632,7 @@ struct sctp_association {
struct sctp_iterator *stcb_starting_point_for_iterator;
/* ASCONF save the last ASCONF-ACK so we can resend it if necessary */
- struct mbuf *last_asconf_ack_sent;
+ struct sctp_asconf_ackhead asconf_ack_sent;
/*
* pointer to last stream reset queued to control queue by us with
@@ -870,7 +880,7 @@ struct sctp_association {
uint32_t refcnt;
uint32_t chunks_on_out_queue; /* total chunks floating around,
* locked by send socket buffer */
-
+ uint32_t peers_adaptation;
uint16_t peer_hmac_id; /* peer HMAC id to send */
/*
@@ -1001,6 +1011,8 @@ struct sctp_association {
uint8_t saw_sack_with_frags;
uint8_t in_restart_hash;
uint8_t assoc_up_sent;
+ uint8_t adaptation_needed;
+ uint8_t adaptation_sent;
/* CMT variables */
uint8_t cmt_dac_pkts_rcvd;
uint8_t sctp_cmt_on_off;
OpenPOWER on IntegriCloud