aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/nat/nat.c
diff options
context:
space:
mode:
authorOle Troan <ot@cisco.com>2019-12-19 11:55:54 +0100
committerAndrew Yourtchenko <ayourtch@gmail.com>2020-02-05 15:45:30 +0000
commit2c6639c695aebf0cd5ac74ad31fd331547fa0126 (patch)
treedd962dda017462107eca0b838c159ea1e19f7b8a /src/plugins/nat/nat.c
parent72e31bc2d9b910147c09e1c329713fccc873a018 (diff)
nat: move dslite to separate sub-plugin
Type: refactor Change-Id: If3d9f16f3a06c10b354f1eef674e8db5f3c44de7 Signed-off-by: Ole Troan <ot@cisco.com>
Diffstat (limited to 'src/plugins/nat/nat.c')
-rwxr-xr-xsrc/plugins/nat/nat.c18
1 files changed, 3 insertions, 15 deletions
diff --git a/src/plugins/nat/nat.c b/src/plugins/nat/nat.c
index 14855323ab7..9f516586877 100755
--- a/src/plugins/nat/nat.c
+++ b/src/plugins/nat/nat.c
@@ -25,7 +25,6 @@
#include <nat/nat_det.h>
#include <nat/nat64.h>
#include <nat/nat66.h>
-#include <nat/dslite.h>
#include <nat/nat_inlines.h>
#include <nat/nat_affinity.h>
#include <nat/nat_syslog.h>
@@ -640,15 +639,6 @@ is_snat_address_used_in_static_mapping (snat_main_t * sm, ip4_address_t addr)
return 0;
}
-void
-increment_v4_address (ip4_address_t * a)
-{
- u32 v;
-
- v = clib_net_to_host_u32 (a->as_u32) + 1;
- a->as_u32 = clib_host_to_net_u32 (v);
-}
-
static void
snat_add_static_mapping_when_resolved (snat_main_t * sm,
ip4_address_t l_addr,
@@ -2507,8 +2497,6 @@ snat_init (vlib_main_t * vm)
if (error)
return error;
- dslite_init (vm);
-
nat66_init (vm);
ip4_table_bind_callback_t cbt4 = {
@@ -3755,7 +3743,7 @@ snat_config (vlib_main_t * vm, unformat_input_t * input)
{
snat_main_t *sm = &snat_main;
nat66_main_t *nm = &nat66_main;
- dslite_main_t *dm = &dslite_main;
+ //dslite_main_t *dm = &dslite_main;
snat_main_per_thread_data_t *tsm;
u32 static_mapping_buckets = 1024;
@@ -3840,8 +3828,8 @@ snat_config (vlib_main_t * vm, unformat_input_t * input)
;
else if (unformat (input, "out2in dpo"))
sm->out2in_dpo = 1;
- else if (unformat (input, "dslite ce"))
- dslite_set_ce (dm, 1);
+ //else if (unformat (input, "dslite ce"))
+ //dslite_set_ce (dm, 1);
else if (unformat (input, "endpoint-dependent"))
sm->endpoint_dependent = 1;
else