From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: [PATCH] examples/ethtool: explicit PCI header dependency Date: Wed, 28 Jun 2017 16:18:19 +0200 Message-ID: <20170628141819.17360-1-thomas@monjalon.net> References: Cc: dev@dpdk.org To: gaetan.rivet@6wind.com Return-path: Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) by dpdk.org (Postfix) with ESMTP id 2E1FE271 for ; Wed, 28 Jun 2017 16:18:42 +0200 (CEST) In-Reply-To: List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" In devargs rework, rte_pci.h won't be included by rte_ethdev.h (via rte_devargs.h) anymore. rte_ethtool_get_drvinfo() could use rte_devargs.name instead of creating equivalent bus specific name. For now, it is workarounded by just including rte_pci.h. Signed-off-by: Thomas Monjalon --- examples/ethtool/lib/rte_ethtool.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/examples/ethtool/lib/rte_ethtool.c b/examples/ethtool/lib/rte_ethtool.c index fabfcb2ba..252382cb5 100644 --- a/examples/ethtool/lib/rte_ethtool.c +++ b/examples/ethtool/lib/rte_ethtool.c @@ -36,6 +36,7 @@ #include #include #include +#include #ifdef RTE_LIBRTE_IXGBE_PMD #include #endif @@ -73,6 +74,7 @@ rte_ethtool_get_drvinfo(uint8_t port_id, struct ethtool_drvinfo *drvinfo) dev_info.driver_name); snprintf(drvinfo->version, sizeof(drvinfo->version), "%s", rte_version()); + /* TODO: replace bus_info by rte_devargs.name */ if (dev_info.pci_dev) snprintf(drvinfo->bus_info, sizeof(drvinfo->bus_info), "%04x:%02x:%02x.%x", -- 2.13.1