diff options
author | Damjan Marion <damarion@cisco.com> | 2022-01-14 11:57:40 +0100 |
---|---|---|
committer | Damjan Marion <damarion@cisco.com> | 2022-01-14 11:58:33 +0100 |
commit | f8dd9d8af135363631e4d3a366e6ccd89431aa99 (patch) | |
tree | 43fb589e6d40ae4a46ab35f97d7126d246b27825 /src/plugins/dpdk/device/format.c | |
parent | e15245d79d67f842c4b35f0a382d85a264c795a0 (diff) |
dpdk: fix burst function output
Type: fix
Fixes: 65105c95f
Change-Id: I8dee4b560a49891f954d7eb8e79ea535cedeaa88
Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/plugins/dpdk/device/format.c')
-rw-r--r-- | src/plugins/dpdk/device/format.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/plugins/dpdk/device/format.c b/src/plugins/dpdk/device/format.c index 3ff66ed96b4..e8aca247be5 100644 --- a/src/plugins/dpdk/device/format.c +++ b/src/plugins/dpdk/device/format.c @@ -506,8 +506,8 @@ format_dpdk_burst_fn (u8 *s, va_list *args) p = (dir == VLIB_TX) ? rte_eth_fp_ops[xd->port_id].tx_pkt_burst : rte_eth_fp_ops[xd->port_id].rx_pkt_burst; - if (dladdr (p, &info) == 0) - return 0; + if (dladdr (p, &info) == 0 || info.dli_sname == 0) + return format (s, "(not available)"); return format (s, "%s", info.dli_sname); } @@ -670,7 +670,7 @@ format_dpdk_device (u8 * s, va_list * args) ""); } - s = format (s, "%Urx burst function: %s\n", format_white_space, indent + 2, + s = format (s, "%Urx burst function: %U\n", format_white_space, indent + 2, format_dpdk_burst_fn, xd, VLIB_TX); /* $$$ MIB counters */ |