summaryrefslogtreecommitdiffstats
path: root/src/plugins/dpdk/device
diff options
context:
space:
mode:
authorNaoyuki Mori <naoyuki.mori@intel.com>2018-09-04 10:36:54 +0900
committerNaoyuki Mori <naoyuki.mori@intel.com>2018-09-04 19:17:41 +0900
commit004869d0d4947a6e56b2d1bd481bbb6916d7a2e0 (patch)
treeeb043ba5c0954bb22419f0a05b8254101faefeed /src/plugins/dpdk/device
parent7eedb5fb44d5a38cb3ba059d6983e95128b97d36 (diff)
Fixed showing negative count in stats show CLI
Some counters (bytes, pkts) are formatted as signed instead of unsigned in "show hardware-interfaces" and "show lb". These stats counters are declared as u64. Change-Id: Id1b588188bff4e36402beb8d07f779e9a5193956 Signed-off-by: Naoyuki Mori <naoyuki.mori@intel.com>
Diffstat (limited to 'src/plugins/dpdk/device')
-rw-r--r--src/plugins/dpdk/device/format.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/dpdk/device/format.c b/src/plugins/dpdk/device/format.c
index be828932c80..70306a8bb06 100644
--- a/src/plugins/dpdk/device/format.c
+++ b/src/plugins/dpdk/device/format.c
@@ -593,7 +593,7 @@ format_dpdk_device (u8 * s, va_list * args)
{
#define _(N, V) \
if ((xd->stats.V - xd->last_cleared_stats.V) != 0) { \
- s = format (s, "\n%U%-40U%16Ld", \
+ s = format (s, "\n%U%-40U%16Lu", \
format_white_space, indent + 2, \
format_c_identifier, #N, \
xd->stats.V - xd->last_cleared_stats.V); \
@@ -625,7 +625,7 @@ format_dpdk_device (u8 * s, va_list * args)
{
/* format_c_identifier doesn't like c strings inside vector */
u8 * name = format(0,"%s", xstat_names[i].name);
- xs = format(xs, "\n%U%-38U%16Ld",
+ xs = format(xs, "\n%U%-38U%16Lu",
format_white_space, indent + 4,
format_c_identifier, name, delta);
vec_free(name);