summaryrefslogtreecommitdiffstats
path: root/src/vnet/interface_output.c
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2021-03-04 18:41:59 +0100
committerOle Tr�an <otroan@employees.org>2021-03-05 11:59:24 +0000
commit8fb5add31885fcee1abaf60dd903aa566cc53b0d (patch)
tree774eddc57568e5cad1cb3c2d4a4956501d21a37b /src/vnet/interface_output.c
parent3efd4e9998192545c32aeb33a9f8f72a1ba085a9 (diff)
interface: move vnet_pcap_t to vnet
It naturally belogns there... Type: refactor Change-Id: I05f7ba01103a5e9b3756f1ea69c8cc5d8f26f0a0 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vnet/interface_output.c')
-rw-r--r--src/vnet/interface_output.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/vnet/interface_output.c b/src/vnet/interface_output.c
index ff315f6abe0..641bd928d59 100644
--- a/src/vnet/interface_output.c
+++ b/src/vnet/interface_output.c
@@ -426,9 +426,10 @@ static_always_inline void vnet_interface_pcap_tx_trace
(vlib_main_t * vm, vlib_node_runtime_t * node, vlib_frame_t * frame,
int sw_if_index_from_buffer)
{
+ vnet_main_t *vnm = vnet_get_main ();
u32 n_left_from, *from;
u32 sw_if_index;
- vnet_pcap_t *pp = &vlib_global_main.pcap;
+ vnet_pcap_t *pp = &vnm->pcap;
if (PREDICT_TRUE (pp->pcap_tx_enable == 0))
return;
@@ -1047,8 +1048,9 @@ VLIB_NODE_FN (interface_drop) (vlib_main_t * vm,
vlib_node_runtime_t * node,
vlib_frame_t * frame)
{
+ vnet_main_t *vnm = vnet_get_main ();
vnet_interface_main_t *im = &vnet_get_main ()->interface_main;
- vnet_pcap_t *pp = &vlib_global_main.pcap;
+ vnet_pcap_t *pp = &vnm->pcap;
if (PREDICT_FALSE (pp->pcap_drop_enable))
pcap_drop_trace (vm, im, pp, frame);