From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id B248F1C01 for ; Mon, 30 Apr 2018 17:41:07 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 30 Apr 2018 08:41:06 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,346,1520924400"; d="scan'208";a="35737844" Received: from dwdohert-ws.ir.intel.com ([163.33.210.60]) by fmsmga007.fm.intel.com with ESMTP; 30 Apr 2018 08:41:06 -0700 From: Declan Doherty To: dev@dpdk.org Cc: Declan Doherty Date: Mon, 30 Apr 2018 16:32:57 +0100 Message-Id: <20180430153258.1101-2-declan.doherty@intel.com> X-Mailer: git-send-email 2.14.3 In-Reply-To: <20180430153258.1101-1-declan.doherty@intel.com> References: <20180430153258.1101-1-declan.doherty@intel.com> Subject: [dpdk-dev] [PATCH 2/3] net/ixgbe: initialise nb_representor_ports value X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Apr 2018 15:41:08 -0000 Initialise rte_ethdev_args nb_representor_ports to zero to handle the case where no devargs are passed to the IXGBE PF on device probe, so that there is no invalid attempts to create representor ports. Coverity Issue: 277231 Fixes: cf80ba6e2038 ("net/ixgbe: add support for representor ports") Signed-off-by: Declan Doherty --- drivers/net/ixgbe/ixgbe_ethdev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/ixgbe/ixgbe_ethdev.c b/drivers/net/ixgbe/ixgbe_ethdev.c index 0ccf55dc8..283dd7e49 100644 --- a/drivers/net/ixgbe/ixgbe_ethdev.c +++ b/drivers/net/ixgbe/ixgbe_ethdev.c @@ -1725,8 +1725,7 @@ eth_ixgbe_pci_probe(struct rte_pci_driver *pci_drv __rte_unused, struct rte_pci_device *pci_dev) { char name[RTE_ETH_NAME_MAX_LEN]; - - struct rte_eth_devargs eth_da; + struct rte_eth_devargs eth_da = { .nb_representor_ports = 0 }; int i, retval; if (pci_dev->device.devargs) { -- 2.14.3