From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 67B94A2EFC for ; Mon, 14 Oct 2019 15:51:25 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 3EDBE2956; Mon, 14 Oct 2019 15:51:25 +0200 (CEST) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id B8DBD1C235 for ; Mon, 14 Oct 2019 15:51:22 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga104.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 14 Oct 2019 06:51:21 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.67,295,1566889200"; d="scan'208";a="198300815" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga003.jf.intel.com with ESMTP; 14 Oct 2019 06:51:21 -0700 Received: from fmsmsx152.amr.corp.intel.com (10.18.125.5) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 14 Oct 2019 06:51:20 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by FMSMSX152.amr.corp.intel.com (10.18.125.5) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 14 Oct 2019 06:51:20 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.176]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.96]) with mapi id 14.03.0439.000; Mon, 14 Oct 2019 21:51:19 +0800 From: "Wang, Haiyue" To: "Ye, Xiaolong" CC: "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH v1] net/ice: avoid the parsed devargs value being overwritten Thread-Index: AQHVfqNEYxdhGAfQhUyNOecowFjvmadZTkAAgADhKFA= Date: Mon, 14 Oct 2019 13:51:18 +0000 Message-ID: References: <20191009130716.80418-1-haiyue.wang@intel.com> <20191014082438.GD3725@intel.com> In-Reply-To: <20191014082438.GD3725@intel.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNzYyOThkNmYtNTMxMi00YjUxLWI2YTMtZWQ0N2NjZGMyZDQ5IiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiUTNsaXNTc1V1UGZrV3pxZEtLeU1aVW80NERXbk1lS1wvcEx6TXRXa0ZDY0JQWEY3RDZOZk5pQzIrU2h3MEZpdHEifQ== x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v1] net/ice: avoid the parsed devargs value being overwritten 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > -----Original Message----- > From: Ye, Xiaolong > Sent: Monday, October 14, 2019 16:25 > To: Wang, Haiyue > Cc: dev@dpdk.org > Subject: Re: [dpdk-dev] [PATCH v1] net/ice: avoid the parsed devargs valu= e being overwritten >=20 > On 10/09, Haiyue Wang wrote: > >If the default dev args 'proto_xtr' is not in the first position, it > >will overwrite the parsed queue map value, so use an new variable to > >save the default. > > > >And enhance the error message printing to show the right information. > > > >Signed-off-by: Haiyue Wang > >--- > > drivers/net/ice/ice_ethdev.c | 44 +++++++++++++++++++++++++----------- > > drivers/net/ice/ice_ethdev.h | 1 + > > 2 files changed, 32 insertions(+), 13 deletions(-) > > >=20 > [snip] >=20 > >@@ -2126,6 +2142,8 @@ ice_dev_close(struct rte_eth_dev *dev) > > rte_free(hw->port_info); > > hw->port_info =3D NULL; > > ice_shutdown_all_ctrlq(hw); > >+ rte_free(pf->proto_xtr); > >+ pf->proto_xtr =3D NULL; >=20 > These two lines seems irrelevant to this patch, I noticed that the resour= ce > free operation was contained in the original patch, and they are removed > unexpectedly by commit bd513ece3c40 ("net/ice: release port upon close"), > sorry for not catching it when reviewing. >=20 > Prefer one individual patch for the fix. >=20 Planed to send two patches, but a little lazy. :) Will do this in v2. > Thanks, > Xiaolong >=20 > > > > dev->dev_ops =3D NULL; > > dev->rx_pkt_burst =3D NULL; > >diff --git a/drivers/net/ice/ice_ethdev.h b/drivers/net/ice/ice_ethdev.h > >index 182c6f611..2fd98817b 100644 > >--- a/drivers/net/ice/ice_ethdev.h > >+++ b/drivers/net/ice/ice_ethdev.h > >@@ -288,6 +288,7 @@ struct ice_pf { > > */ > > struct ice_devargs { > > int safe_mode_support; > >+ uint8_t proto_xtr_dflt; > > uint8_t proto_xtr[ICE_MAX_QUEUE_NUM]; > > }; > > > >-- > >2.17.1 > >