X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=app%2Fproc-info%2Fmain.c;h=b9587f7ded60adc6d163ba584b053d556924d983;hb=5e2226f194027d3b3e35cb5b444d126928433017;hp=106b44d6fba42c96c9f0bc5ad3558cabf7645bf2;hpb=c923be82e06844384c5a4b62df957bf4be6a0af3;p=dpdk.git diff --git a/app/proc-info/main.c b/app/proc-info/main.c index 106b44d6fb..b9587f7ded 100644 --- a/app/proc-info/main.c +++ b/app/proc-info/main.c @@ -5,6 +5,7 @@ #include #include #include +#include #include #include #include @@ -645,11 +646,16 @@ metrics_display(int port_id) } static void -show_security_context(uint16_t portid) +show_security_context(uint16_t portid, bool inline_offload) { - void *p_ctx = rte_eth_dev_get_sec_ctx(portid); + void *p_ctx; const struct rte_security_capability *s_cap; + if (inline_offload) + p_ctx = rte_eth_dev_get_sec_ctx(portid); + else + p_ctx = rte_cryptodev_get_sec_ctx(portid); + if (p_ctx == NULL) return; @@ -856,7 +862,7 @@ show_port(void) } #ifdef RTE_LIB_SECURITY - show_security_context(i); + show_security_context(i, true); #endif } } @@ -1220,7 +1226,7 @@ show_crypto(void) } #ifdef RTE_LIB_SECURITY - show_security_context(i); + show_security_context(i, false); #endif } } @@ -1264,8 +1270,6 @@ show_ring(char *name) static void show_mempool(char *name) { - uint64_t flags = 0; - snprintf(bdr_str, MAX_STRING_LEN, " show - MEMPOOL "); STATS_BDR_STR(10, bdr_str); @@ -1273,8 +1277,8 @@ show_mempool(char *name) struct rte_mempool *ptr = rte_mempool_lookup(name); if (ptr != NULL) { struct rte_mempool_ops *ops; + uint64_t flags = ptr->flags; - flags = ptr->flags; ops = rte_mempool_get_ops(ptr->ops_index); printf(" - Name: %s on socket %d\n" " - flags:\n"