diff options
author | Marco Varlese <marco.varlese@suse.com> | 2018-03-05 15:12:29 +0100 |
---|---|---|
committer | Damjan Marion <dmarion.lists@gmail.com> | 2018-03-05 18:41:26 +0000 |
commit | c7fe4f39bca709a9ca094ffd4465490fa780a576 (patch) | |
tree | 4b310511183637a02c4f92a81b2557aa547cdb06 /src/vnet/sctp/sctp_api.c | |
parent | 53da221b13225695516ec7469ca29d82bb10e594 (diff) |
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 <marco.varlese@suse.com>
Diffstat (limited to 'src/vnet/sctp/sctp_api.c')
-rw-r--r-- | src/vnet/sctp/sctp_api.c | 17 |
1 files changed, 16 insertions, 1 deletions
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 <vnet/sctp/sctp.api.h> #undef vl_msg_name_crc_list |