pg: remove no-recycle option 26/17726/2
authorDamjan Marion <damarion@cisco.com>
Wed, 20 Feb 2019 13:15:25 +0000 (14:15 +0100)
committerFlorin Coras <florin.coras@gmail.com>
Wed, 20 Feb 2019 16:29:35 +0000 (16:29 +0000)
Change-Id: Ic47bde2d08b2719b5c6c87cb2e9a8af0d2160e6e
Signed-off-by: Damjan Marion <damarion@cisco.com>
41 files changed:
src/scripts/vnet/arp4
src/scripts/vnet/arp4-mpls
src/scripts/vnet/arp6
src/scripts/vnet/bvi
src/scripts/vnet/icmp
src/scripts/vnet/icmp6
src/scripts/vnet/ip6
src/scripts/vnet/ip6-hbh
src/scripts/vnet/l2efpfilter
src/scripts/vnet/l2efpfilter_perf
src/scripts/vnet/l2fib
src/scripts/vnet/l2fib_perf
src/scripts/vnet/l2fib_xc
src/scripts/vnet/l2flood
src/scripts/vnet/l2tp
src/scripts/vnet/lfib/ip4-to-mpls
src/scripts/vnet/lfib/mpls-pop-to-mpls
src/scripts/vnet/lfib/mpls-to-ip4
src/scripts/vnet/lfib/mpls-to-mpls
src/scripts/vnet/mcast/ip4
src/scripts/vnet/mpls-o-ethernet/pg
src/scripts/vnet/mpls-tunnel
src/scripts/vnet/nat44
src/scripts/vnet/nat44_det
src/scripts/vnet/nat44_lb
src/scripts/vnet/nat44_static
src/scripts/vnet/nat44_static_with_port
src/scripts/vnet/nat64
src/scripts/vnet/nat64_static
src/scripts/vnet/pcap
src/scripts/vnet/rewrite
src/scripts/vnet/rpf
src/scripts/vnet/source_and_port_range_check
src/scripts/vnet/srp
src/scripts/vnet/tcp
src/scripts/vnet/udp
src/scripts/vnet/uri/udp
src/scripts/vnet/urpf
src/scripts/vnet/vlan
src/vnet/pg/cli.c
src/vnet/pg/pg.h

index acb20da..372d82a 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.0.0.2
     ICMP echo_request
index d3d39f3..3e15611 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.2.2.2
     ICMP echo_request
index e6a9893..df58fb6 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 64-64
-  no-recycle
   data {
     ICMP6: 2000::2 -> 2001::2
     ICMP echo_request
index 2174da0..124fa04 100644 (file)
@@ -41,7 +41,6 @@ cle run
 packet-generator new {
   name bvi_to_l2 
   limit 100
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
@@ -53,7 +52,6 @@ packet-generator new {
 packet-generator new {
   name l2_to_bvi
   limit 50
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/2/0
   data {
@@ -65,7 +63,6 @@ packet-generator new {
 packet-generator new {
   name l2_to_bvi_via_flood
   limit 25
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/2/0
   data {
index 1e054e2..889eca8 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.2.3.4 -> 5.6.7.8
     ICMP echo_request
index 2a65acb..4fcb600 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 64-64
-  no-recycle
   data {
     ICMP6: ::1 -> ::2
     ICMP echo_request
index adb2722..de6a8e8 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ethernet-input
   size 64-64
-  no-recycle
   data {
     IP6: 1.2.3 -> 4.5.6
     ICMP: 3002::2 -> 3001::2
index 0c6de47..87be118 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 48-48
-  no-recycle
   data {
     IP6_HOP_BY_HOP_OPTIONS: 1::2 -> 1::2
     hex 0x3B00010403040506
@@ -18,7 +17,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 48-48
-  no-recycle
   data {
     IP6_HOP_BY_HOP_OPTIONS: 1::2 -> 1::2
     hex 0x3B00C10403040506
@@ -31,7 +29,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 48-48
-  no-recycle
   data {
     IP6_HOP_BY_HOP_OPTIONS: 1::2 -> 1::2
     hex 0x3BffC10403040506
@@ -44,7 +41,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 64-64
-  no-recycle
   data {
     IP6_HOP_BY_HOP_OPTIONS: 1::2 -> 1::2
     hex 0x3BffC10403040506
@@ -57,7 +53,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 56-56
-  no-recycle
   data {
     IP6_HOP_BY_HOP_OPTIONS: 1::2 -> 1::2
     length 16
@@ -71,7 +66,6 @@ packet-generator new {
   limit 1
   node ip6-input
   size 56-56
-  no-recycle
   data {
     IP6_HOP_BY_HOP_OPTIONS: 1::2 -> 1::2
     length 16
index 307b443..d1074ce 100644 (file)
@@ -48,7 +48,6 @@ clear int
 packet-generator new {
   name pre_vtr_fail
   limit 10
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
@@ -60,7 +59,6 @@ packet-generator new {
 packet-generator new {
   name post_vtr_pass
   limit 20
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
@@ -72,7 +70,6 @@ packet-generator new {
 packet-generator new {
   name post_vtr_fail
   limit 50
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
index b2f4b49..08c1b46 100644 (file)
@@ -48,7 +48,6 @@ clear int
 packet-generator new {
   name post_vtr_pass
   limit 9111003
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
index 81ede17..dd5c5a8 100644 (file)
@@ -28,7 +28,6 @@ clear int
 packet-generator new {
   name new_input_if_index_mac_move
   limit 4
-  no-recycle
   node ethernet-input 
   interface GigabitEthernet2/1/0
   size 98-98
@@ -38,7 +37,6 @@ packet-generator new {
 packet-generator new {
   name dmac_hit
   limit 7
-  no-recycle
   node ethernet-input 
   interface GigabitEthernet2/2/0
   size 98-98
index 638317f..5556506 100644 (file)
@@ -20,7 +20,6 @@ cle run
 packet-generator new {
   name perf
   limit 9111003
-  no-recycle
   node ethernet-input 
   interface GigabitEthernet2/2/0.1 
   size 98-98
index 35d7342..bb25bd3 100644 (file)
@@ -22,7 +22,6 @@ clear int
 packet-generator new {
   name xc
   limit 11
-  no-recycle
   node ethernet-input 
   interface GigabitEthernet2/1/0
   size 98-98
index 013462c..ec82306 100644 (file)
@@ -30,7 +30,6 @@ clear int
 packet-generator new {
   name flood
   limit 1
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
index 337805a..fcfe4b5 100644 (file)
@@ -42,7 +42,6 @@ packet-generator new {
   name decap
   limit 10
   size 200-200
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/2/0
   data {
@@ -59,7 +58,6 @@ packet-generator new {
   name decap_bad_sid
   limit 30
   size 200-200
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/2/0
   data {
@@ -76,7 +74,6 @@ packet-generator new {
   name decap_bad_cookie
   limit 50
   size 200-200
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/2/0
   data {
@@ -92,7 +89,6 @@ packet-generator new {
 packet-generator new {
   name encap
   limit 100
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
@@ -106,7 +102,6 @@ packet-generator new {
   name decap_sublayer
   limit 300
   size 200-200
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/2/0
   data {
@@ -122,7 +117,6 @@ packet-generator new {
 packet-generator new {
   name encap_sublayer
   limit 700
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
index 8575379..c792329 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.2.2.2
     ICMP echo_request
index 2818ac1..1b7ef8d 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node mpls-input
   size 72-72
-  no-recycle
   data {
    hex 0x0001e0ff0001f1ff4500004000000000400177ba010000020202020208007a6e000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f2021222324252627
   }
index 24e235e..4bd707f 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node mpls-input
   size 68-68
-  no-recycle
   data {
    hex 0x0001e1ff4500004000000000400177ba010000020202020208007a6e000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f2021222324252627
   }
index 497dbab..07015d2 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node mpls-input
   size 68-68
-  no-recycle
   data {
    hex 0x0001e1ff4500004000000000400177ba010000020200000208007a6e000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f2021222324252627
   }
index eb6bab2..101f09b 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 512-512
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 232.1.1.1
     ICMP echo_request
index ba5397f..4070cde 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node mpls-ethernet-input
   size 68-68
-  no-recycle
   data {
    hex 0x0001e1ff4500004000000000400177ba010000020200000208007a6e000102030405060708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f2021222324252627
   }
index d04b297..e69ad6b 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.0.0.2
     ICMP echo_request
@@ -15,7 +14,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.0.1.2
     ICMP echo_request
@@ -27,7 +25,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.0.2.2
     ICMP echo_request
@@ -39,7 +36,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.0.3.2
     ICMP echo_request
index 3292b56..bce9648 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   interface pg0
   data {
     UDP: 10.0.0.3 -> 172.16.1.2
@@ -21,7 +20,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   interface pg0
   data {
     UDP: 10.0.0.3 -> 172.16.1.2
index 629772e..ad1e7bb 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 0
   interface pg0
   data {
@@ -22,7 +21,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 1
   interface pg0
   data {
@@ -38,7 +36,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 0
   interface pg1
   data {
@@ -54,7 +51,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 1
   interface pg1
   data {
@@ -70,7 +66,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 2
   interface pg0
   data {
@@ -86,7 +81,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 1
   interface pg1
   data {
index f66c13c..0e47635 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 0
   interface pg1
   data {
@@ -22,7 +21,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 1
   interface pg1
   data {
index 2b8f25e..26e3408 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 0
   interface pg0
   data {
@@ -22,7 +21,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 1
   interface pg1
   data {
index 25e16e9..7297fb4 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 0
   interface pg0
   data {
@@ -22,7 +21,6 @@ packet-generator new {
   limit 1000000
   node ip4-input
   size 64-64
-  no-recycle
   worker 1
   interface pg1
   data {
index f0d98ea..85cd179 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 10
   node ip6-input
   size 64-64
-  no-recycle
   worker 0
   interface pg0
   data {
@@ -22,7 +21,6 @@ packet-generator new {
   limit 10
   node ip6-input
   size 64-64
-  no-recycle
   interface pg0
   worker 1
   data {
index ff5e8db..3cf682d 100644 (file)
@@ -6,7 +6,6 @@ packet-generator new {
   limit 10
   node ip4-input
   size 64-64
-  no-recycle
   worker 0
   interface pg1
   data {
@@ -22,7 +21,6 @@ packet-generator new {
   limit 10
   node ip4-input
   size 64-64
-  no-recycle
   interface pg1
   worker 1
   data {
index 692e5f2..d8f47c6 100644 (file)
@@ -2,7 +2,6 @@ packet-generator new {
   name x
   limit 1
   node ethernet-input
-  no-recycle
   pcap /home/eliot/pcap-data/ISIS_level1_adjacency.cap
 }
 
@@ -10,7 +9,6 @@ packet-generator new {
   name y
   limit 1
   node hdlc-input
-  no-recycle
   pcap /home/eliot/pcap-data/ISIS_p2p_adjacency.cap
 }
 
index d41b9db..d05ce89 100644 (file)
@@ -26,7 +26,6 @@ cle run
 packet-generator new {
   name toport
   limit 2
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
@@ -38,7 +37,6 @@ packet-generator new {
 packet-generator new {
   name tovlan
   limit 2
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
@@ -50,7 +48,6 @@ packet-generator new {
 packet-generator new {
   name toqinq
   limit 2
-  no-recycle
   node ethernet-input
   interface GigabitEthernet2/1/0
   data {
index 571c6b7..7a6608e 100644 (file)
@@ -3,7 +3,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.2.3.4 -> 5.6.7.8
     ICMP echo_request
index dce227b..7eabde3 100644 (file)
@@ -9,7 +9,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 1.2.3.4 -> 5.6.7.8
     UDP: 3000 -> 3001
@@ -22,7 +21,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 1.1.1.1 -> 5.6.7.8
     UDP: 3000 -> 3001
@@ -35,7 +33,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 1.1.1.1 -> 5.6.7.8
     UDP: 6000 -> 6001
index 7cc3701..c20b38a 100644 (file)
@@ -8,7 +8,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     ICMP: 1.0.0.2 -> 2.0.0.2
     ICMP echo_request
index b9c23c3..8c6c107 100644 (file)
@@ -8,7 +8,6 @@ packet-generator new {
   node ip4-input
   size 100-100
   interface loop0
-  no-recycle
   data {
     TCP: 192.168.1.2 -> 192.168.1.1
     TCP: 32415 -> 80
index 7dda1ee..8e3b75b 100644 (file)
@@ -9,7 +9,6 @@ packet-generator new {
   node ip4-input
   size 100-100
   interface loop0
-  no-recycle
   data {
    UDP: 192.168.1.2 - 192.168.2.255 -> 192.168.1.1
    UDP: 4321 -> 1234
index 3ab4292..bbbe2c1 100644 (file)
@@ -15,7 +15,6 @@ packet-generator new {
   node ip4-input
   size 100-100
   interface loop0
-  no-recycle
   data {
    UDP: 192.168.1.2 - 192.168.2.255 -> 192.168.1.1
    UDP: 4321 -> 1234
index a4d8752..1268ff5 100644 (file)
@@ -9,7 +9,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 1.2.3.4 -> 2.2.2.2
     UDP: 3000 -> 3001
@@ -22,7 +21,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 1.1.1.1 -> 2.2.2.2
     UDP: 3000 -> 3001
@@ -35,7 +33,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 11.11.12.13 -> 2.2.2.2
     UDP: 6000 -> 6001
@@ -48,7 +45,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 11.11.12.13 -> 10.10.10.10
     UDP: 6000 -> 6001
@@ -61,7 +57,6 @@ packet-generator new {
   limit 1
   node ip4-input
   size 64-64
-  no-recycle
   data {
     UDP: 1.1.1.1 -> 10.10.10.10
     UDP: 3000 -> 3001
index 076080a..eb3359e 100644 (file)
@@ -9,7 +9,6 @@ packet-generator new {
   node ethernet-input
   interface fake-eth0
   size 64-64
-  no-recycle
   data {
     IP4: 1.2.3 -> 4.5.6 vlan 1
     ICMP: 1.2.3.4 -> 5.6.7.8
index 803db12..834ec48 100644 (file)
@@ -267,8 +267,6 @@ pg_pcap_read (pg_stream_t * s, char *file_name)
   s->min_packet_bytes = pm.min_packet_bytes;
   s->max_packet_bytes = pm.max_packet_bytes;
   s->buffer_bytes = pm.max_packet_bytes;
-  /* For PCAP buffers we never re-use buffers. */
-  s->flags |= PG_STREAM_FLAGS_DISABLE_BUFFER_RECYCLE;
 
   if (s->n_packets_limit == 0)
     s->n_packets_limit = vec_len (pm.packets_read);
@@ -387,9 +385,6 @@ new_stream (vlib_main_t * vm,
       else if (unformat_user (input, unformat_pg_stream_parameter, &s))
        ;
 
-      else if (unformat (input, "no-recycle"))
-       s.flags |= PG_STREAM_FLAGS_DISABLE_BUFFER_RECYCLE;
-
       else
        {
          error = clib_error_create ("unknown input `%U'",
index bc3b03b..c0e000f 100644 (file)
@@ -100,7 +100,6 @@ typedef struct pg_stream_t
 
   /* Stream is currently enabled. */
 #define PG_STREAM_FLAGS_IS_ENABLED (1 << 0)
-#define PG_STREAM_FLAGS_DISABLE_BUFFER_RECYCLE (1 << 1)
 
   /* Edit groups are created by each protocol level (e.g. ethernet,
      ip4, tcp, ...). */