From: Muhammad Ahmad <muhammad.ahmad@emumba.com>
To: wenzhuo.lu@intel.com, jingjing.wu@intel.com,
bernard.iremonger@intel.com, ferruh.yigit@intel.com
Cc: Muhammad Ahmad <muhammad.ahmad@emumba.com>, dev@dpdk.org
Subject: [dpdk-dev] [PATCH v3] testpmd: added rte_eth_dev_fw_version_get in testpmd
Date: Thu, 19 Mar 2020 12:44:00 +0500 [thread overview]
Message-ID: <20200319074400.14139-1-muhammad.ahmad@emumba.com> (raw)
In-Reply-To: <20200318152227.3931-1-muhammad.ahmad@emumba.com>
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=y, Size: 1482 bytes --]
rte_eth_dev_fw_version_get() was not called in test pmd.
Added rte_eth_dev_fw_version_get() in testpmd under
show port info <port no>
Bugzilla ID: 225
Cc: dev@dpdk.org
Reported-by: Thomas Monjalon <thomas@monjalon.net>
Signed-off-by: Muhammad Ahmad <muhammad.ahmad@emumba.com>
---
app/test-pmd/config.c | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index 8cf84ccd3..66f3de908 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -52,6 +52,8 @@
#include "testpmd.h"
+#define ETHDEV_FWVERS_LEN 32
+
static char *flowtype_to_str(uint16_t flow_type);
static const struct {
@@ -523,6 +525,7 @@ port_infos_display(portid_t port_id)
uint16_t mtu;
char name[RTE_ETH_NAME_MAX_LEN];
int ret;
+ char fw_version[ETHDEV_FWVERS_LEN];
if (port_id_is_invalid(port_id, ENABLED_WARN)) {
print_valid_ports();
@@ -544,6 +547,13 @@ port_infos_display(portid_t port_id)
rte_eth_dev_get_name_by_port(port_id, name);
printf("\nDevice name: %s", name);
printf("\nDriver name: %s", dev_info.driver_name);
+
+ if (rte_eth_dev_fw_version_get(port_id, fw_version,
+ ETHDEV_FWVERS_LEN) == 0)
+ printf("\nFirmware-version: %s", fw_version);
+ else
+ printf("\nFirmware-version: %s", "not available");
+
if (dev_info.device->devargs && dev_info.device->devargs->args)
printf("\nDevargs: %s", dev_info.device->devargs->args);
printf("\nConnect to socket: %u", port->socket_id);
--
2.17.1
next prev parent reply other threads:[~2020-03-19 7:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-18 15:22 [dpdk-dev] [PATCH v2] " Muhammad Ahmad
2020-03-18 15:33 ` Ferruh Yigit
2020-03-19 7:44 ` Muhammad Ahmad [this message]
2020-03-20 4:17 ` [dpdk-dev] [PATCH v3] " Kalesh Anakkur Purayil
2020-03-20 6:46 ` [dpdk-dev] [PATCH v4] app/testpmd: add fw version in port info Muhammad Ahmad
2020-03-20 10:35 ` Ferruh Yigit
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200319074400.14139-1-muhammad.ahmad@emumba.com \
--to=muhammad.ahmad@emumba.com \
--cc=bernard.iremonger@intel.com \
--cc=dev@dpdk.org \
--cc=ferruh.yigit@intel.com \
--cc=jingjing.wu@intel.com \
--cc=wenzhuo.lu@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).