aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-01-21 09:03:10 -0800
committerFlorin Coras <florin.coras@gmail.com>2019-01-21 19:34:15 +0000
commit0cb68778ecdf2d46a8cf3183356ef0ba6af1ed44 (patch)
treeb6d5988551ef7c4aedaed6d284459d9d659ab91e /src
parent1705599efe5eec09c09d2214da776d92d0e4f1cf (diff)
ldp: add support for TCP_CONGESTION sockopts (VPP-1550)v19.01-rc2
Change-Id: I0fcf3385cc4fb96f000b84d5f880f74131c0d60f Signed-off-by: Florin Coras <fcoras@cisco.com> (cherry picked from commit 0ed24e93b207850078ca7f58cd4106cc4a906952)
Diffstat (limited to 'src')
-rw-r--r--src/vcl/ldp.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/vcl/ldp.c b/src/vcl/ldp.c
index 9f195c64a1b..088c118b6ed 100644
--- a/src/vcl/ldp.c
+++ b/src/vcl/ldp.c
@@ -1700,6 +1700,11 @@ getsockopt (int fd, int level, int optname,
else
rv = -EFAULT;
break;
+ case TCP_CONGESTION:
+ strcpy (optval, "cubic");
+ *optlen = strlen ("cubic");
+ rv = 0;
+ break;
default:
LDBG (0, "ERROR: fd %d: getsockopt SOL_TCP: sid %u, "
"optname %d unsupported!", fd, vlsh, optname);
@@ -1808,6 +1813,10 @@ setsockopt (int fd, int level, int optname,
rv = vls_attr (vlsh, VPPCOM_ATTR_SET_TCP_KEEPINTVL,
(void *) optval, &optlen);
break;
+ case TCP_CONGESTION:
+ /* Ignore */
+ rv = 0;
+ break;
default:
LDBG (0, "ERROR: fd %d: setsockopt() SOL_TCP: vlsh %u"
"optname %d unsupported!", fd, vlsh, optname);