diff options
author | Neale Ranns <nranns@cisco.com> | 2020-10-08 14:02:35 +0000 |
---|---|---|
committer | Neale Ranns <nranns@cisco.com> | 2020-10-08 14:02:35 +0000 |
commit | 0e12131f8bf519fb301d4a2e34c3e0a4944da796 (patch) | |
tree | bb706b5d4cbe4551e74ce52792058a01c28de740 | |
parent | 533bf08cf491a9b74cf761abf05709248a80b274 (diff) |
pg: Choose the input interface from the stream's rx
Type: fix
Signed-off-by: Neale Ranns <nranns@cisco.com>
Change-Id: I656918a417d33ec6bea30054805e03ae19c38f2d
-rw-r--r-- | src/scripts/vnet/mpls-to-dot1ad | 2 | ||||
-rw-r--r-- | src/vnet/pg/input.c | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/src/scripts/vnet/mpls-to-dot1ad b/src/scripts/vnet/mpls-to-dot1ad index 93d3a701595..ea8418e70e8 100644 --- a/src/scripts/vnet/mpls-to-dot1ad +++ b/src/scripts/vnet/mpls-to-dot1ad @@ -43,7 +43,7 @@ packet-generator new { name v2g limit 1 node ethernet-input - interface pg1.12 + interface pg1 data { hex 0x000000000011005056b77c8388a80020810000210102030405060708 } diff --git a/src/vnet/pg/input.c b/src/vnet/pg/input.c index 60fc96e6faa..c8f3d9f01d8 100644 --- a/src/vnet/pg/input.c +++ b/src/vnet/pg/input.c @@ -1623,9 +1623,11 @@ pg_generate_packets (vlib_node_runtime_t * node, u8 feature_arc_index = fm->device_input_feature_arc_index; cm = &fm->feature_config_mains[feature_arc_index]; u32 current_config_index = ~(u32) 0; - pg_interface_t *pi = pool_elt_at_index (pg->interfaces, s->pg_if_index); + pg_interface_t *pi; int i; + pi = pool_elt_at_index (pg->interfaces, + pg->if_id_by_sw_if_index[s->sw_if_index[VLIB_RX]]); bi0 = s->buffer_indices; n_packets_in_fifo = pg_stream_fill (pg, s, n_packets_to_generate); |