From c7fe4f39bca709a9ca094ffd4465490fa780a576 Mon Sep 17 00:00:00 2001 From: Marco Varlese Date: Mon, 5 Mar 2018 15:12:29 +0100 Subject: SCTP: API to configure some tunables This patch adds the possibility to configure some behaviors of the SCTP stack based on some tunable parameters (mainly ON/OFF). For the time being, that is limited to the bundling option (multiplexing messages) and to delaying the SACK message. Change-Id: I696493e0309e47163c1e119c7d9f82f7d8ee6b87 Signed-off-by: Marco Varlese --- src/vnet/sctp/sctp_api.c | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'src/vnet/sctp/sctp_api.c') diff --git a/src/vnet/sctp/sctp_api.c b/src/vnet/sctp/sctp_api.c index 6aac77d2826..5f93040effc 100644 --- a/src/vnet/sctp/sctp_api.c +++ b/src/vnet/sctp/sctp_api.c @@ -42,7 +42,8 @@ #define foreach_sctp_api_msg \ _(SCTP_ADD_SRC_DST_CONNECTION, sctp_add_src_dst_connection) \ -_(SCTP_DEL_SRC_DST_CONNECTION, sctp_del_src_dst_connection) +_(SCTP_DEL_SRC_DST_CONNECTION, sctp_del_src_dst_connection) \ +_(SCTP_CONFIG, sctp_config) static void vl_api_sctp_add_src_dst_connection_t_handler @@ -81,6 +82,20 @@ static void REPLY_MACRO (VL_API_SCTP_ADD_SRC_DST_CONNECTION_REPLY); } +static void +vl_api_sctp_config_t_handler (vl_api_sctp_config_t * mp) +{ + sctp_user_configuration_t config; + vl_api_sctp_config_reply_t *rmp; + int rv; + + config.never_delay_sack = mp->never_delay_sack; + config.never_bundle = mp->never_bundle; + rv = sctp_configure (config); + + REPLY_MACRO (VL_API_SCTP_CONFIG_REPLY); +} + #define vl_msg_name_crc_list #include #undef vl_msg_name_crc_list -- cgit 1.2.3-korg