Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev dpdk new counters #82

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

srajag
Copy link
Contributor

@srajag srajag commented Jun 10, 2015

No description provided.

Please test with DPDK 2.0 with proper patches applied.

Change-Id: Idab7b02bd7bd058f8da33f44f6826f8b14d4e4f7
dpdk_if_tx():
  Call vif_get_stats() before .f_tx(). Move .f_stats() just after .f_tx()
  is called. Increment ring dequeue drops if TX queue does not exist.
dpdk_if_rx():
  Call vif_get_stats() before .f_tx(). Move .f_stats() just after .f_tx()
  is called. Increment ring dequeue drops if TX queue does not exist.
dpdk_lcore_fwd_io():
  Move .f_stats() just after .f_tx() is called.
dpdk_virtio_to_vm_flush():
  Move DPDK_VIRTIO_WRITER_STATS_PKTS_DROP_ADD() outside a packet freeing for loop.
vr_dpdk_virtio_enq_pkts_to_phys_lcore():
  Move vr_stats->vis_rngenqdrops++ outside a packet freeing for loop.

Change-Id: Ia1dabe618894e986eb98d7ce9e6c14a219b382a2
Add iftxrngenqpkts and iftxrngenqdrops.
Remove rngdeqpackets and rngdeqdrops.
Rename ifenqpackets to ifenqpkts.
Rename ifdeqpackets to ifdeqpkts.
Rename rngenqpackets and rngenqdrops to ifrxenqpkts and ifrxenqdrops.
Add proper comments in places where they get incremented.

Update stats after .f_flush() in vr_dpdk_lcore_flush().
Not sure if do the same in dpdk_lcore_tx_queue_remove(), so add a comment only.

Add a comment about future incrementation of vis_ifrenqpkts for physical vif,
when we finally implement MPLSoGRE hashing.

Show new counters in vif utility.
Packets enqueued on RX ring should be displayed for virtual interfaces.

Change-Id: Icfccb967e5e06ac2d6ef8780d92d7b67f4cc6f2b
req->vifr_ifdeqpkts = 0;
req->vifr_ifdeqdrops = 0;
req->vifr_ifrxenqpkts = 0;
req->vifr_ifrxenqdrops = 0;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change to vifr_ifrxrng as you suggested.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

- cleanups in counters definitions (better names, order of definition)
- cleanups in per-core stats (fix some conditions, add comments).
- cleanups in vif utility (fix some whitespaces, add comments).
- in dpdk_lcore_tx_queue_remove() remove unnecessary comment.
- move iDPDK_VIRTIO_WRITER_STATS_PKTS_IN_ADD() macro to f._tx() from
  .f_flush().
- in vr_dpdk_virtio.c/.h rename in/out_stats to vdv_in/out_stats.
- in vr_dpdk_lcore_flush() check if .f_flush() writes to device or ring.
- change code updating port_stats into functions: dpdk_port_out_stats_update()
  and dpdk_port_in_stats_update().
- in vr_interfaces.c when we build answer for request with stats, fix
  operators += -> =.
- in vr_dpdk_lcore_flush() don't update stats for agent, because it's interface
  does not use port_stats structures, but increments vis_ counters directly.
Now you can call vif with additional parameter: --core or -C
with --list or --get parameter.

Example:
vif --list --core 2
vif --get 3 -C 2

Change-Id: Ibd6d26b153b609a81d61fc83054413928a842b28
Change-Id: If10b162fbaa04c26410240570414753be76e9e7a
Change-Id: Iee05c00b62991e9beb80782e5b79fdb9534fc6b1
@semihalf-zmuda-wojciech semihalf-zmuda-wojciech deleted the dev-dpdk-new-counters branch September 4, 2015 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants