From f126e746fc01c75bc99329d10ce9127b26b23814 Mon Sep 17 00:00:00 2001 From: Klement Sekera Date: Thu, 10 Oct 2019 09:46:06 +0000 Subject: nat: use SVR Remove NAT's implementation of shallow virtual reassembly with corresponding CLIs, APIs & tests. Replace with standalone shallow virtual reassembly provided by ipX-sv-reass* nodes. Type: refactor Change-Id: I7e6c7487a5a500d591f6871474a359e0993e59b6 Signed-off-by: Klement Sekera --- src/plugins/nat/nat66.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/plugins/nat/nat66.c') diff --git a/src/plugins/nat/nat66.c b/src/plugins/nat/nat66.c index e5e783b31f7..3ac773c7da4 100644 --- a/src/plugins/nat/nat66.c +++ b/src/plugins/nat/nat66.c @@ -19,6 +19,7 @@ #include #include +#include nat66_main_t nat66_main; @@ -29,11 +30,13 @@ VNET_FEATURE_INIT (nat66_in2out, static) = { .arc_name = "ip6-unicast", .node_name = "nat66-in2out", .runs_before = VNET_FEATURES ("ip6-lookup"), + .runs_after = VNET_FEATURES ("ip6-sv-reassembly-feature"), }; VNET_FEATURE_INIT (nat66_out2in, static) = { .arc_name = "ip6-unicast", .node_name = "nat66-out2in", .runs_before = VNET_FEATURES ("ip6-lookup"), + .runs_after = VNET_FEATURES ("ip6-sv-reassembly-feature"), }; /* *INDENT-ON* */ @@ -99,6 +102,9 @@ nat66_interface_add_del (u32 sw_if_index, u8 is_inside, u8 is_add) } feature_name = is_inside ? "nat66-in2out" : "nat66-out2in"; + int rv = ip6_sv_reass_enable_disable_with_refcnt (sw_if_index, is_add); + if (rv) + return rv; return vnet_feature_enable_disable ("ip6-unicast", feature_name, sw_if_index, is_add, 0, 0); } -- cgit 1.2.3-korg