From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by dpdk.org (Postfix) with ESMTP id D3F29F04; Wed, 13 Sep 2017 04:37:41 +0200 (CEST) Received: from fmsmga002.fm.intel.com ([10.253.24.26]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 12 Sep 2017 19:37:39 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.42,385,1500966000"; d="scan'208";a="1218061300" Received: from dpdk11.sh.intel.com ([10.67.110.198]) by fmsmga002.fm.intel.com with ESMTP; 12 Sep 2017 19:37:39 -0700 From: Jingjing Wu To: beilei.xing@intel.com Cc: dev@dpdk.org, jingjing.wu@intel.com, stable@dpdk.org Date: Wed, 13 Sep 2017 03:20:02 +0800 Message-Id: <1505244002-51248-1-git-send-email-jingjing.wu@intel.com> X-Mailer: git-send-email 2.7.4 Subject: [dpdk-dev] [PATCH] net/i40e: fix memory leak if VF init fails 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: Wed, 13 Sep 2017 02:37:42 -0000 Cc: stable@dpdk.org Fixes: 4861cde46116 ("i40e: new poll mode driver") Signed-off-by: Jingjing Wu --- drivers/net/i40e/i40e_ethdev_vf.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/net/i40e/i40e_ethdev_vf.c b/drivers/net/i40e/i40e_ethdev_vf.c index f6d8293..9eca9ed 100644 --- a/drivers/net/i40e/i40e_ethdev_vf.c +++ b/drivers/net/i40e/i40e_ethdev_vf.c @@ -1317,6 +1317,8 @@ i40evf_init_vf(struct rte_eth_dev *dev) err_alloc: rte_free(vf->vf_res); + rte_free(vf->aq_resp); + vf->vsi_res = NULL; err_aq: i40e_shutdown_adminq(hw); /* ignore error */ err: -- 2.7.4