Age | Commit message (Collapse) | Author | Files | Lines |
|
As a FUD reduction measure, this patch implements 2-way parallel
counter collection. Synthetic stat component counter pairs run at the
same time. Running two counters (of any kind) at the same time
naturally reduces the aggregate time required by an approximate
factor-of-2, depending on whether an even or odd number of stats have
been requested.
I don't completely buy the argument that computing synthetic stats
such as instructions-per-clock will be inaccurate if component counter
values are collected sequentially. Given uniform traffic pattern, it
must make no difference.
As the collection interval increases, the difference between serial
and parallel component counter collection will approach zero, see also
the Central Limit theorem.
Change-Id: I36ebdcf125e8882cca8a1929ec58f17fba1ad8f1
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
Change-Id: I9df96264e30806ac3daf7121f314f34f06232413
Signed-off-by: Damjan Marion <damjan.marion@gmail.com>
|
|
Change-Id: I1c12e2941cae198ededbb65eb5be51a4eabe2c1b
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: I0ba5175be077c40556f2a3ce629c5bbcd71e0a81
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: I5fe01e918b534d1ac1d47f0d7610536f45c3158c
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: Ia083050389853c25b069f0f8286d50d3f4aef527
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: I3bb1d9f83dd08f4b93acd4a281bfec0674e39c2e
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: If88ccd965122b9318a39a8d71b53334cd1fd81e4
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
1. Otherwise, the log classes with same prefix, e.g. "abc" and
"abc-de" will all be registered into log class "abc";
2. Minor improvement for test log help string.
Change-Id: I8d93be5e8fa67db6012198b3442a9e2bddcb744a
Signed-off-by: Su Wang <su.z.wang@ericsson.com>
|
|
For some reason, GCC 8 in debian is pickier than GCC 8 in ubuntu. It complains
about things in strncpy like this
/home/sluong/vpp/src/vlib/linux/pci.c:485:7: error: ‘strncpy’ output may be
truncated copying 15 bytes from a string of length 255 [-Werror=stringop-truncation]
strncpy (ifr.ifr_name, e->d_name, sizeof (ifr.ifr_name) - 1);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/sluong/vpp/src/vlib/linux/pci.c: At top level:
It also complains similar things in string_test.c
The fix in pci.c is to convert strncpy to use clib_strncpy
The fix in string_test.c is condiational compile the complained code for GCC 8.
Change-Id: Ic9341ca54ed7407210502197a28283bc42c26662
Signed-off-by: Steven Luong <sluong@cisco.com>
|
|
Change-Id: I6048c6a51efa826ac333f7d15919cb87dd766d74
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: Idb224b807373128b78dc46f177b2d2e0ed288349
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
This reverts commit 1e59f9ddbdda14591967e1d66eab8623f9ba58e4.
Change-Id: Iae1d372b887e170d28cac2fe4c61325ee5a5894a
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Storing buffer in local template seems to be better option....
Change-Id: I1a2fdd68cb956f99a5b36d2cd810fc623e089bcf
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
The code that was manipulating interface names with ifreq was
causing warnings about possible truncation and non terminated
strings.
These are warnings only since kernel would allow a interface
name > 15 characters anyway.
Change-Id: I794a94fe310b8568403d4e3523c61d53468a6f02
Reported-by: Burt Silverman <burtms@gmail.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
|
|
Doing strncpy(ifr.ifr_name, s, sizeof(ifr.ifr_name)) will cause
a warning about string truncation with GCC 8 (and other tools).
Fix this by using sizeof(ifr.ifr_name) - 1. Also, there is no
need to manually zero the end of the string since the whole
ifr structure is already zeroed by memset.
Change-Id: I9440d602ecdd9f8592b69bab2e77479146d00d76
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
|
|
Change-Id: Ia34a4278eedc8cf450688b1fa0291e1f976868d3
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
Change-Id: Ic56ee4ce83b282a5f0f5aed500721fe639b941b3
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
It's not OK to crash due to a transient buffer allocation failure.
Return 1 if the requested operation failed, otherwise 0.
Buffer index parameter change to a value-result, so the caller can
differentiate between partial and complete allocation failure: callers
which request an initial allocation (inbound bi = ~0) need to check
the (out) value to decide whether or not to call vlib_buffer_free(...).
Change-Id: I03029d7f2714c17dca4630dfd95a1eb578b68384
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
Change-Id: I31a3ff9e8f70468196c091027592a3aed2d09ac3
Signed-off-by: Paul Vinciguerra <pvinci@vinciconsulting.com>
|
|
Change-Id: If2bbfbc52994f5de0879763e0b7a7864498debb6
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
This patch adds support for VMBus to the VPP infrastructure.
Since the only device that matters is the netvsc Poll Mode Driver
in DPDK, the infrastructure is much simpler than PCI.
Change-Id: Ie96c897ad9c426716c2398e4528688ce2217419b
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
|
|
Change-Id: Iacaa75c7e1c974642c1dc1e0c3cf5c36c78450d7
Signed-off-by: Matus Fabian <matfabia@cisco.com>
|
|
replace vlib_buffer_advance with its code to work around assert
Change-Id: I6e332527f5e0c10d23305b6fc2e837d8b4f99e78
Signed-off-by: Klement Sekera <ksekera@cisco.com>
|
|
Add a check to make sure that the vlib and vnet buffer flag bit
definitions do not overlap.
The VNET_BUFFER_F_AVAIL1...8 definitions allow out-of-tree codes to:
#define VNET_BUFFER_F_MY_USECASE VNET_BUFFER_F_AVAIL1
and so on. This avoids introducing irrelevant and/or proprietary bit
definitions into vnet/buffer.h, and hopefully minimizes merge pain for
everyone involved.
Change-Id: I5be4f61dceb81b5bfca005f6d609ade074af205b
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
VPP graph dispatch trace record description:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Major Version | Minor Version | NStrings | ProtoHint |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Buffer index (big endian) |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
+ VPP graph node name ... ... | NULL octet |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Buffer Metadata ... ... | NULL octet |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Buffer Opaque ... ... | NULL octet |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Buffer Opaque 2 ... ... | NULL octet |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| VPP ASCII packet trace (if NStrings > 4) | NULL octet |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Packet data (up to 16K) |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Graph dispatch records comprise a version stamp, an indication of how
many NULL-terminated strings will follow the record header, and a
protocol hint.
The buffer index allows downstream consumers of these data to easily
filter/track single packets as they traverse the forwarding
graph. FWIW, the 32-bit buffer index is stored in big endian format.
As of this writing, major version = 1, minor version = 0. Nstrings
will be either 4 or 5.
Here is the current set of protocol hints:
typedef enum
{
VLIB_NODE_PROTO_HINT_NONE = 0,
VLIB_NODE_PROTO_HINT_ETHERNET,
VLIB_NODE_PROTO_HINT_IP4,
VLIB_NODE_PROTO_HINT_IP6,
VLIB_NODE_PROTO_HINT_TCP,
VLIB_NODE_PROTO_HINT_UDP,
VLIB_NODE_N_PROTO_HINTS,
} vlib_node_proto_hint_t;
Example: VLIB_NODE_PROTO_HINT_IP6 means that the first octet of packet
data SHOULD be 0x60, and should begin an ipv6 packet header.
Change-Id: Idf310bad80cc0e4207394c80f18db5f77c378741
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
fixes a problem seen when dhcp proxy uses vlib_buffer_chain_linearize
function which tries to vlib_buffer_alloc zero buffers - which succeeds
if the buffers vector is initialized but otherwise crashes when trying to
update the _vec_len in vlib_buffer_alloc_from_free_list
solved by initializing the free_list buffers vec
Change-Id: I1186d7aac05e54864d72f3f144e1bef8064f8efa
Signed-off-by: Eyal Bari <ebari@cisco.com>
|
|
Change-Id: I56f25d653b71a25c70e6c5c1a93dd9c5158f2079
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
Change-Id: I8f4843e7a961a1e6c3fd057554b31ae49fc9b328
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: I485dd07ea0fe032bdd5990567578e73e9bcffe1e
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
dhcp packets might (when flooded) arrive in chains of cloned buffers
Change-Id: Ifddecd656b6a5d6ba8cd94184f5c021684e35548
Signed-off-by: Eyal Bari <ebari@cisco.com>
|
|
Change-Id: Iba750a41262cc028ad0363fff78cc219e4a33538
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
To facilitate dispatch trajectory tracing, vlib_buffer_t decoding, etc.
through Wireshark
Change-Id: I31356b9fa1f40cba8830aaf10a86a9fbb7546438
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
Change-Id: Id4f37f5d4a03160572954a416efa1ef9b3d79ad1
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
Change-Id: I88c3d3e516401bb1c84991515cd701c156ae19dd
Signed-off-by: Eyal Bari <ebari@cisco.com>
|
|
Typically we have scalar_size == 0, so it doesn't matter
but vlib_frame_args was providing pointer to scalar frame
data, not vector data. To avoid future confusion function
is renamed to vlib_frame_scalar_args(...)
Change-Id: I48b75523b46d487feea24f3f3cb10c528dde516f
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
This patch adds support for mapping the virtual address to physical
address and size of memory allocated.
Change-Id: I7659a1881308e89b215c486fecd7c973076d0773
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
|
|
Avoids crash if suspended_process_frames grows.
Change-Id: Id26ef0dd0dd001b997c531c4dec004e7e7989670
Signed-off-by: Florin Coras <fcoras@cisco.com>
|
|
Change-Id: I9b5f7b264f9978e3dd97b2d1eb103b7d10ac3170
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: I2476e3e916a42b41d1e66bfc1ec4f8c4264c1720
Signed-off-by: Dave Barach <dbarach@cisco.com>
|
|
Thread 1 "vpp_main" received signal SIGSEGV, Segmentation fault.
0x00007ffff670da53 in cj_dump_one_record (r=0x7ffff50f0fec)
at /home/sluong/vpp3/vpp/src/vlib/unix/cj.c:138
138 (long long unsigned int) r->data[1]);
(gdb) p *cjm
$1 = {tail = 58645908, records = 0x7fffb64646ec, num_records = 512,
enable = 1, vlib_main = 0x7ffff6953240 <vlib_global_main>}
(gdb) p /x cjm
$2 = 0x7ffff6953880
(gdb) p /x *cjm
$3 = {tail = 0x37edd94, records = 0x7fffb64646ec, num_records = 0x200,
enable = 0x1, vlib_main = 0x7ffff6953240}
(gdb)
cjm->tail is a 64 bit counter, not the total number of records. Dumping from
0 to cjm->tail can be a very large number of records which go beyond the
limit. I believe we meant to dump from 0 to index. index has been set by
this statement
index = (cjm->tail + 1) & (cjm->num_records - 1);
Change-Id: Ie1a8ba757598de9757accc1488577c15aa49726b
Signed-off-by: Steven <sluong@cisco.com>
|
|
This reverts commit 71615399e194847d7833b744caedab9b841733e5.
There seems to be an issue with ARPs when running with multiple workers.
Change-Id: Iaa68081512362945a9caf24dcb8d70fc7c5b75df
Signed-off-by: Florin Coras <fcoras@cisco.com>
|
|
Change-Id: Iecceffe06a92660976ebb58cd3cbec4be8931db0
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Few devices provide PCI bar region(s) through I/O.
If any such device driver opens I/O "fd" to read and write,
needs to close it, when pci device is going to be deleted.
Change-Id: Iba104e56f76c6bf9ccd27bf2223bad39b1301763
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
|
|
Change-Id: Ib5c346641463768cf33eaf8cb5fab5b63171398d
Signed-off-by: Dave Barach <dave@barachs.net>
|
|
Change-Id: Ie9ff9b751190632dfc4576e5cbb1987a4142af5e
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: Icb8172238f735fd0825e474e16a006f1435e175c
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: I9d96e7782a12c2e19eacbb75edb1fb450cf33bed
Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
|
|
Change-Id: If36be24fa08e21c7718a1dced506a7f254dfb5cf
Signed-off-by: Damjan Marion <damarion@cisco.com>
|
|
Change-Id: Ic4c46bc733afae8bf0d8146623ed15633928de30
Signed-off-by: Damjan Marion <damarion@cisco.com>
|