diff options
Diffstat (limited to 'src/plugins')
-rw-r--r-- | src/plugins/flowprobe/flowprobe.c | 115 | ||||
-rw-r--r-- | src/plugins/ioam/analyse/ioam_summary_export.c | 23 | ||||
-rw-r--r-- | src/plugins/ioam/analyse/ioam_summary_export.h | 10 | ||||
-rw-r--r-- | src/plugins/ioam/udp-ping/udp_ping_export.c | 27 | ||||
-rw-r--r-- | src/plugins/nat/lib/ipfix_logging.c | 152 |
5 files changed, 149 insertions, 178 deletions
diff --git a/src/plugins/flowprobe/flowprobe.c b/src/plugins/flowprobe/flowprobe.c index ff49b0b94e4..713ff8bce32 100644 --- a/src/plugins/flowprobe/flowprobe.c +++ b/src/plugins/flowprobe/flowprobe.c @@ -202,10 +202,9 @@ flowprobe_template_l4_fields (ipfix_field_specifier_t * f) * @returns u8 * vector containing the indicated IPFIX template packet */ static inline u8 * -flowprobe_template_rewrite_inline (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, +flowprobe_template_rewrite_inline (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, flowprobe_variant_t which) { @@ -223,7 +222,6 @@ flowprobe_template_rewrite_inline (flow_report_main_t * frm, flowprobe_main_t *fm = &flowprobe_main; flowprobe_record_t flags = fr->opaque.as_uword; bool collect_ip4 = false, collect_ip6 = false; - ipfix_exporter_t *exp = pool_elt_at_index (frm->exporters, 0); stream = &exp->streams[fr->stream_index]; @@ -310,73 +308,62 @@ flowprobe_template_rewrite_inline (flow_report_main_t * frm, } static u8 * -flowprobe_template_rewrite_ip6 (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index) +flowprobe_template_rewrite_ip6 (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return flowprobe_template_rewrite_inline - (frm, fr, collector_address, src_address, collector_port, - FLOW_VARIANT_IP6); + return flowprobe_template_rewrite_inline ( + exp, fr, collector_address, src_address, collector_port, FLOW_VARIANT_IP6); } static u8 * -flowprobe_template_rewrite_ip4 (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index) +flowprobe_template_rewrite_ip4 (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return flowprobe_template_rewrite_inline - (frm, fr, collector_address, src_address, collector_port, - FLOW_VARIANT_IP4); + return flowprobe_template_rewrite_inline ( + exp, fr, collector_address, src_address, collector_port, FLOW_VARIANT_IP4); } static u8 * -flowprobe_template_rewrite_l2 (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index) +flowprobe_template_rewrite_l2 (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return flowprobe_template_rewrite_inline - (frm, fr, collector_address, src_address, collector_port, - FLOW_VARIANT_L2); + return flowprobe_template_rewrite_inline ( + exp, fr, collector_address, src_address, collector_port, FLOW_VARIANT_L2); } static u8 * -flowprobe_template_rewrite_l2_ip4 (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, +flowprobe_template_rewrite_l2_ip4 (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index) + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return flowprobe_template_rewrite_inline - (frm, fr, collector_address, src_address, collector_port, - FLOW_VARIANT_L2_IP4); + return flowprobe_template_rewrite_inline (exp, fr, collector_address, + src_address, collector_port, + FLOW_VARIANT_L2_IP4); } static u8 * -flowprobe_template_rewrite_l2_ip6 (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, +flowprobe_template_rewrite_l2_ip6 (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index) + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return flowprobe_template_rewrite_inline - (frm, fr, collector_address, src_address, collector_port, - FLOW_VARIANT_L2_IP6); + return flowprobe_template_rewrite_inline (exp, fr, collector_address, + src_address, collector_port, + FLOW_VARIANT_L2_IP6); } /** @@ -390,27 +377,27 @@ flowprobe_template_rewrite_l2_ip6 (flow_report_main_t * frm, * will be sent. */ vlib_frame_t * -flowprobe_data_callback_ip4 (flow_report_main_t * frm, - flow_report_t * fr, - vlib_frame_t * f, u32 * to_next, u32 node_index) +flowprobe_data_callback_ip4 (flow_report_main_t *frm, ipfix_exporter_t *exp, + flow_report_t *fr, vlib_frame_t *f, u32 *to_next, + u32 node_index) { flowprobe_flush_callback_ip4 (); return f; } vlib_frame_t * -flowprobe_data_callback_ip6 (flow_report_main_t * frm, - flow_report_t * fr, - vlib_frame_t * f, u32 * to_next, u32 node_index) +flowprobe_data_callback_ip6 (flow_report_main_t *frm, ipfix_exporter_t *exp, + flow_report_t *fr, vlib_frame_t *f, u32 *to_next, + u32 node_index) { flowprobe_flush_callback_ip6 (); return f; } vlib_frame_t * -flowprobe_data_callback_l2 (flow_report_main_t * frm, - flow_report_t * fr, - vlib_frame_t * f, u32 * to_next, u32 node_index) +flowprobe_data_callback_l2 (flow_report_main_t *frm, ipfix_exporter_t *exp, + flow_report_t *fr, vlib_frame_t *f, u32 *to_next, + u32 node_index) { flowprobe_flush_callback_l2 (); return f; @@ -423,7 +410,7 @@ flowprobe_template_add_del (u32 domain_id, u16 src_port, vnet_flow_rewrite_callback_t * rewrite_callback, bool is_add, u16 * template_id) { - flow_report_main_t *frm = &flow_report_main; + ipfix_exporter_t *exp = &flow_report_main.exporters[0]; vnet_flow_report_add_del_args_t a = { .rewrite_callback = rewrite_callback, .flow_data_callback = flow_data_callback, @@ -432,7 +419,7 @@ flowprobe_template_add_del (u32 domain_id, u16 src_port, .src_port = src_port, .opaque.as_uword = flags, }; - return vnet_flow_report_add_del (frm, &a, template_id); + return vnet_flow_report_add_del (exp, &a, template_id); } static void diff --git a/src/plugins/ioam/analyse/ioam_summary_export.c b/src/plugins/ioam/analyse/ioam_summary_export.c index 141c03a97de..c9cc0770a8c 100644 --- a/src/plugins/ioam/analyse/ioam_summary_export.c +++ b/src/plugins/ioam/analyse/ioam_summary_export.c @@ -20,11 +20,11 @@ #include <ioam/analyse/ip6/ip6_ioam_analyse.h> u8 * -ioam_template_rewrite (flow_report_main_t * frm, flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index) +ioam_template_rewrite (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { ip4_header_t *ip; udp_header_t *udp; @@ -38,7 +38,6 @@ ioam_template_rewrite (flow_report_main_t * frm, flow_report_t * fr, u32 field_count = 0; u32 field_index = 0; flow_report_stream_t *stream; - ipfix_exporter_t *exp = pool_elt_at_index (frm->exporters, 0); stream = &exp->streams[fr->stream_index]; @@ -265,8 +264,9 @@ ioam_analyse_add_ipfix_record (flow_report_t * fr, } vlib_frame_t * -ioam_send_flows (flow_report_main_t * frm, flow_report_t * fr, - vlib_frame_t * f, u32 * to_next, u32 node_index) +ioam_send_flows (flow_report_main_t *frm, ipfix_exporter_t *exp, + flow_report_t *fr, vlib_frame_t *f, u32 *to_next, + u32 node_index) { vlib_buffer_t *b0 = NULL; u32 next_offset = 0; @@ -280,13 +280,12 @@ ioam_send_flows (flow_report_main_t * frm, flow_report_t * fr, u32 records_this_buffer; u16 new_l0, old_l0; ip_csum_t sum0; - vlib_main_t *vm = frm->vlib_main; + vlib_main_t *vm = vlib_get_main (); ip6_address_t temp; ioam_analyser_data_t *record = NULL; flow_report_stream_t *stream; ioam_analyser_data_t *aggregated_data; u16 data_len; - ipfix_exporter_t *exp = pool_elt_at_index (frm->exporters, 0); stream = &exp->streams[fr->stream_index]; @@ -401,7 +400,7 @@ ioam_flow_create (u8 del) vnet_flow_report_add_del_args_t args; int rv; u32 domain_id = 0; - flow_report_main_t *frm = &flow_report_main; + ipfix_exporter_t *exp = &flow_report_main.exporters[0]; u16 template_id; clib_memset (&args, 0, sizeof (args)); @@ -410,7 +409,7 @@ ioam_flow_create (u8 del) del ? (args.is_add = 0) : (args.is_add = 1); args.domain_id = domain_id; - rv = vnet_flow_report_add_del (frm, &args, &template_id); + rv = vnet_flow_report_add_del (exp, &args, &template_id); switch (rv) { diff --git a/src/plugins/ioam/analyse/ioam_summary_export.h b/src/plugins/ioam/analyse/ioam_summary_export.h index 99890ad43d9..8c604b9b04a 100644 --- a/src/plugins/ioam/analyse/ioam_summary_export.h +++ b/src/plugins/ioam/analyse/ioam_summary_export.h @@ -65,11 +65,11 @@ typedef struct clib_error_t *ioam_flow_create (u8 del); -u8 *ioam_template_rewrite (flow_report_main_t * frm, flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index); +u8 *ioam_template_rewrite (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index); u16 ioam_analyse_add_ipfix_record (flow_report_t * fr, ioam_analyser_data_t * record, diff --git a/src/plugins/ioam/udp-ping/udp_ping_export.c b/src/plugins/ioam/udp-ping/udp_ping_export.c index 84d8ddf9e93..d8926aa01d4 100644 --- a/src/plugins/ioam/udp-ping/udp_ping_export.c +++ b/src/plugins/ioam/udp-ping/udp_ping_export.c @@ -23,20 +23,20 @@ #define UDP_PING_EXPORT_RECORD_SIZE 400 static u8 * -udp_ping_template_rewrite (flow_report_main_t * frm, flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, u16 collector_port, - ipfix_report_element_t * elts, - u32 n_elts, u32 * stream_index) +udp_ping_template_rewrite (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return ioam_template_rewrite (frm, fr, collector_address, - src_address, collector_port, elts, n_elts, - stream_index); + return ioam_template_rewrite (exp, fr, collector_address, src_address, + collector_port, elts, n_elts, stream_index); } static vlib_frame_t * -udp_ping_send_flows (flow_report_main_t * frm, flow_report_t * fr, - vlib_frame_t * f, u32 * to_next, u32 node_index) +udp_ping_send_flows (flow_report_main_t *frm, ipfix_exporter_t *exp, + flow_report_t *fr, vlib_frame_t *f, u32 *to_next, + u32 node_index) { vlib_buffer_t *b0 = NULL; u32 next_offset = 0; @@ -50,13 +50,12 @@ udp_ping_send_flows (flow_report_main_t * frm, flow_report_t * fr, u32 records_this_buffer; u16 new_l0, old_l0; ip_csum_t sum0; - vlib_main_t *vm = frm->vlib_main; + vlib_main_t *vm = vlib_get_main (); flow_report_stream_t *stream; udp_ping_flow_data *stats; ip46_udp_ping_flow *ip46_flow; u16 src_port, dst_port; u16 data_len; - ipfix_exporter_t *exp = pool_elt_at_index (frm->exporters, 0); stream = &exp->streams[fr->stream_index]; data_len = vec_len (udp_ping_main.ip46_flow); @@ -231,7 +230,7 @@ udp_ping_flow_create (u8 del) vnet_flow_report_add_del_args_t args; int rv; u32 domain_id = 0; - flow_report_main_t *frm = &flow_report_main; + ipfix_exporter_t *exp = &flow_report_main.exporters[0]; u16 template_id; clib_memset (&args, 0, sizeof (args)); @@ -241,7 +240,7 @@ udp_ping_flow_create (u8 del) args.domain_id = domain_id; args.src_port = UDP_DST_PORT_ipfix; - rv = vnet_flow_report_add_del (frm, &args, &template_id); + rv = vnet_flow_report_add_del (exp, &args, &template_id); switch (rv) { diff --git a/src/plugins/nat/lib/ipfix_logging.c b/src/plugins/nat/lib/ipfix_logging.c index 9bdb50dc1c3..0b67a34b200 100644 --- a/src/plugins/nat/lib/ipfix_logging.c +++ b/src/plugins/nat/lib/ipfix_logging.c @@ -143,12 +143,10 @@ do { \ * @returns template packet */ static inline u8 * -nat_template_rewrite (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - nat_event_t event, quota_exceed_event_t quota_event) +nat_template_rewrite (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + nat_event_t event, quota_exceed_event_t quota_event) { nat_ipfix_logging_main_t *silm = &nat_ipfix_logging_main; ip4_header_t *ip; @@ -163,7 +161,6 @@ nat_template_rewrite (flow_report_main_t * frm, u32 field_count = 0; flow_report_stream_t *stream; u32 stream_index; - ipfix_exporter_t *exp = pool_elt_at_index (frm->exporters, 0); stream = &exp->streams[fr->stream_index]; @@ -391,97 +388,86 @@ nat_template_rewrite (flow_report_main_t * frm, } u8 * -nat_template_rewrite_addr_exhausted (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t *elts, - u32 n_elts, u32 *stream_index) +nat_template_rewrite_addr_exhausted (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, + u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return nat_template_rewrite (frm, fr, collector_address, src_address, - collector_port, NAT_ADDRESSES_EXHAUTED, 0); + return nat_template_rewrite (exp, fr, collector_address, src_address, + collector_port, NAT_ADDRESSES_EXHAUTED, 0); } u8 * -nat_template_rewrite_nat44_session (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t *elts, - u32 n_elts, u32 *stream_index) +nat_template_rewrite_nat44_session (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, + u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return nat_template_rewrite (frm, fr, collector_address, src_address, - collector_port, NAT44_SESSION_CREATE, 0); + return nat_template_rewrite (exp, fr, collector_address, src_address, + collector_port, NAT44_SESSION_CREATE, 0); } u8 * -nat_template_rewrite_max_entries_per_usr (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t *elts, - u32 n_elts, u32 *stream_index) +nat_template_rewrite_max_entries_per_usr ( + ipfix_exporter_t *exp, flow_report_t *fr, ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, ipfix_report_element_t *elts, + u32 n_elts, u32 *stream_index) { - return nat_template_rewrite (frm, fr, collector_address, src_address, - collector_port, QUOTA_EXCEEDED, - MAX_ENTRIES_PER_USER); + return nat_template_rewrite (exp, fr, collector_address, src_address, + collector_port, QUOTA_EXCEEDED, + MAX_ENTRIES_PER_USER); } u8 * -nat_template_rewrite_max_sessions (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, +nat_template_rewrite_max_sessions (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, - ipfix_report_element_t *elts, - u32 n_elts, u32 *stream_index) + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return nat_template_rewrite (frm, fr, collector_address, src_address, - collector_port, QUOTA_EXCEEDED, - MAX_SESSION_ENTRIES); + return nat_template_rewrite (exp, fr, collector_address, src_address, + collector_port, QUOTA_EXCEEDED, + MAX_SESSION_ENTRIES); } u8 * -nat_template_rewrite_max_bibs (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t *elts, - u32 n_elts, u32 *stream_index) +nat_template_rewrite_max_bibs (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return nat_template_rewrite (frm, fr, collector_address, src_address, - collector_port, QUOTA_EXCEEDED, - MAX_BIB_ENTRIES); + return nat_template_rewrite (exp, fr, collector_address, src_address, + collector_port, QUOTA_EXCEEDED, + MAX_BIB_ENTRIES); } u8 * -nat_template_rewrite_nat64_bib (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t *elts, - u32 n_elts, u32 *stream_index) +nat_template_rewrite_nat64_bib (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return nat_template_rewrite (frm, fr, collector_address, src_address, - collector_port, NAT64_BIB_CREATE, 0); + return nat_template_rewrite (exp, fr, collector_address, src_address, + collector_port, NAT64_BIB_CREATE, 0); } u8 * -nat_template_rewrite_nat64_session (flow_report_main_t * frm, - flow_report_t * fr, - ip4_address_t * collector_address, - ip4_address_t * src_address, - u16 collector_port, - ipfix_report_element_t *elts, - u32 n_elts, u32 *stream_index) +nat_template_rewrite_nat64_session (ipfix_exporter_t *exp, flow_report_t *fr, + ip4_address_t *collector_address, + ip4_address_t *src_address, + u16 collector_port, + ipfix_report_element_t *elts, u32 n_elts, + u32 *stream_index) { - return nat_template_rewrite (frm, fr, collector_address, src_address, - collector_port, NAT64_SESSION_CREATE, 0); + return nat_template_rewrite (exp, fr, collector_address, src_address, + collector_port, NAT64_SESSION_CREATE, 0); } static inline void @@ -1479,11 +1465,11 @@ nat_ipfix_logging_nat64_session (u32 thread_index, } vlib_frame_t * -data_callback (flow_report_main_t * frm, flow_report_t * fr, - vlib_frame_t * f, u32 * to_next, u32 node_index) +data_callback (flow_report_main_t *frm, ipfix_exporter_t *exp, + flow_report_t *fr, vlib_frame_t *f, u32 *to_next, + u32 node_index) { nat_ipfix_logging_main_t *silm = &nat_ipfix_logging_main; - ipfix_exporter_t *exp = pool_elt_at_index (frm->exporters, 0); if (PREDICT_FALSE (++silm->call_counter >= vec_len (exp->reports))) { @@ -1507,7 +1493,7 @@ int nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) { nat_ipfix_logging_main_t *silm = &nat_ipfix_logging_main; - flow_report_main_t *frm = &flow_report_main; + ipfix_exporter_t *exp = &flow_report_main.exporters[0]; vnet_flow_report_add_del_args_t a; int rv; u8 e = enable ? 1 : 0; @@ -1522,7 +1508,7 @@ nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) a.flow_data_callback = data_callback; a.rewrite_callback = nat_template_rewrite_nat44_session; - rv = vnet_flow_report_add_del (frm, &a, NULL); + rv = vnet_flow_report_add_del (exp, &a, NULL); if (rv) { //nat_elog_warn_X1 ("vnet_flow_report_add_del returned %d", "i4", rv); @@ -1530,7 +1516,7 @@ nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) } a.rewrite_callback = nat_template_rewrite_addr_exhausted; - rv = vnet_flow_report_add_del (frm, &a, NULL); + rv = vnet_flow_report_add_del (exp, &a, NULL); if (rv) { //nat_elog_warn_X1 ("vnet_flow_report_add_del returned %d", "i4", rv); @@ -1538,7 +1524,7 @@ nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) } a.rewrite_callback = nat_template_rewrite_max_sessions; - rv = vnet_flow_report_add_del (frm, &a, NULL); + rv = vnet_flow_report_add_del (exp, &a, NULL); if (rv) { //nat_elog_warn_X1 ("vnet_flow_report_add_del returned %d", "i4", rv); @@ -1546,7 +1532,7 @@ nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) } a.rewrite_callback = nat_template_rewrite_max_bibs; - rv = vnet_flow_report_add_del (frm, &a, NULL); + rv = vnet_flow_report_add_del (exp, &a, NULL); if (rv) { //nat_elog_warn_X1 ("vnet_flow_report_add_del returned %d", "i4", rv); @@ -1554,7 +1540,7 @@ nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) } a.rewrite_callback = nat_template_rewrite_nat64_bib; - rv = vnet_flow_report_add_del (frm, &a, NULL); + rv = vnet_flow_report_add_del (exp, &a, NULL); if (rv) { //nat_elog_warn_X1 ("vnet_flow_report_add_del returned %d", "i4", rv); @@ -1562,7 +1548,7 @@ nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) } a.rewrite_callback = nat_template_rewrite_nat64_session; - rv = vnet_flow_report_add_del (frm, &a, NULL); + rv = vnet_flow_report_add_del (exp, &a, NULL); if (rv) { //nat_elog_warn_X1 ("vnet_flow_report_add_del returned %d", "i4", rv); @@ -1572,7 +1558,7 @@ nat_ipfix_logging_enable_disable (int enable, u32 domain_id, u16 src_port) // if endpoint dependent per user max entries is also required /* a.rewrite_callback = nat_template_rewrite_max_entries_per_usr; - rv = vnet_flow_report_add_del (frm, &a, NULL); + rv = vnet_flow_report_add_del (exp, &a, NULL); if (rv) { //nat_elog_warn_X1 ("vnet_flow_report_add_del returned %d", "i4", rv); |