diff options
author | Nathan Skrzypczak <nathan.skrzypczak@gmail.com> | 2021-02-25 11:14:53 +0100 |
---|---|---|
committer | Florin Coras <florin.coras@gmail.com> | 2021-02-26 01:55:07 +0000 |
commit | 4d237874e5c9922330c62ac1b003a9a171c1bc3b (patch) | |
tree | 3ce74a3e85659124653e8406635bec29e156b9f2 /src/plugins/cnat/cnat_types.c | |
parent | 27647a27c7b1e800547e3a3ea97b099b25618177 (diff) |
cnat: Add maglev support
* Backend choice in translations is controlled
by lb_type switch allowing to enable Maglev.
* Size of pool is set with cnat { maglev-len 1009 }
Type: feature
Change-Id: I956e19d70bc9f3b997b4f8042831164e4b559d17
Signed-off-by: Nathan Skrzypczak <nathan.skrzypczak@gmail.com>
Diffstat (limited to 'src/plugins/cnat/cnat_types.c')
-rw-r--r-- | src/plugins/cnat/cnat_types.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/plugins/cnat/cnat_types.c b/src/plugins/cnat/cnat_types.c index b6c6628961c..74c1c24389f 100644 --- a/src/plugins/cnat/cnat_types.c +++ b/src/plugins/cnat/cnat_types.c @@ -185,6 +185,7 @@ cnat_config (vlib_main_t * vm, unformat_input_t * input) cm->session_max_age = CNAT_DEFAULT_SESSION_MAX_AGE; cm->tcp_max_age = CNAT_DEFAULT_TCP_MAX_AGE; cm->default_scanner_state = CNAT_SCANNER_ON; + cm->maglev_len = CNAT_DEFAULT_MAGLEV_LEN; cm->lazy_init_done = 0; while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT) @@ -217,6 +218,8 @@ cnat_config (vlib_main_t * vm, unformat_input_t * input) ; else if (unformat (input, "tcp-max-age %u", &cm->tcp_max_age)) ; + else if (unformat (input, "maglev-len %u", &cm->maglev_len)) + ; else return clib_error_return (0, "unknown input '%U'", format_unformat_error, input); |