From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 781462C6E for ; Thu, 13 Apr 2017 10:55:26 +0200 (CEST) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 13 Apr 2017 01:55:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.37,194,1488873600"; d="scan'208";a="845395693" Received: from kmsmsx153.gar.corp.intel.com ([172.21.73.88]) by FMSMGA003.fm.intel.com with ESMTP; 13 Apr 2017 01:55:23 -0700 Received: from pgsmsx103.gar.corp.intel.com ([169.254.2.175]) by KMSMSX153.gar.corp.intel.com ([169.254.5.83]) with mapi id 14.03.0319.002; Thu, 13 Apr 2017 16:55:22 +0800 From: "Zhao1, Wei" To: "Ananyev, Konstantin" , Thomas Monjalon CC: "Mcnamara, John" , "dev@dpdk.org" , "Lu, Wenzhuo" Thread-Topic: [dpdk-dev] [PATCH v4 1/3] lib/librte_ether: add support for port reset Thread-Index: AQHSqTm8K6Xc/Z+bh0WPnxNjoB7PqKGtRo6AgAplLjD//8WxAIAAoiDg//98+ICAC4Ha0A== Date: Thu, 13 Apr 2017 08:55:22 +0000 Message-ID: References: <1490866456-52241-1-git-send-email-wei.zhao1@intel.com> <2969664.trJitADFWx@xps13> <2978037.PdPlo8nOdn@xps13> <2601191342CEEE43887BDE71AB9772583FAE5871@IRSMSX109.ger.corp.intel.com> In-Reply-To: <2601191342CEEE43887BDE71AB9772583FAE5871@IRSMSX109.ger.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [172.30.20.205] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v4 1/3] lib/librte_ether: add support for port reset 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: Thu, 13 Apr 2017 08:55:27 -0000 Hi, Konstantin > -----Original Message----- > From: Ananyev, Konstantin > Sent: Thursday, April 6, 2017 5:03 PM > To: Zhao1, Wei ; Thomas Monjalon > > Cc: Mcnamara, John ; dev@dpdk.org; Lu, > Wenzhuo > Subject: RE: [dpdk-dev] [PATCH v4 1/3] lib/librte_ether: add support for = port > reset >=20 >=20 >=20 > > -----Original Message----- > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Zhao1, Wei > > Sent: Thursday, April 6, 2017 9:53 AM > > To: Thomas Monjalon > > Cc: Mcnamara, John ; dev@dpdk.org; Lu, > > Wenzhuo > > Subject: Re: [dpdk-dev] [PATCH v4 1/3] lib/librte_ether: add support > > for port reset > > > > Hi, Thomas > > > > > -----Original Message----- > > > From: Thomas Monjalon [mailto:thomas.monjalon@6wind.com] > > > Sent: Thursday, April 6, 2017 3:11 PM > > > To: Zhao1, Wei > > > Cc: Mcnamara, John ; dev@dpdk.org; Lu, > > > Wenzhuo > > > Subject: Re: [dpdk-dev] [PATCH v4 1/3] lib/librte_ether: add support > > > for port reset > > > > > > 2017-04-06 02:57, Zhao1, Wei: > > > > > /** > > > > > > + * Reset an ethernet device when it's not working. One > > > > > > + scenario is, after PF > > > > > > + * port is down and up, the related VF port should be reset. > > > > > > + * The API will stop the port, clear the rx/tx queues, > > > > > > + re-setup the rx/tx > > > > > > + * queues, restart the port. > > > > > > > > > > s/The API/This function/ > > > > > > > > > > Please explain exactly the responsibility of this function, and > > > > > how it is different from calling stop/configure/start. > > > > > > > > In this reset feature, reset function can do the calling > > > > stop/configure/start process, but also It can also do some restore > > > > work for the port, for example, it can restore the added > > > > parameters of > > > vlan, mac_addrs, promisc_unicast_enabled falg and > > > promisc_multicast_enabled flag. >=20 > Ok, but why start/stop can't do these things? > Konstantin This is because in i40e PMD code, start and stop process do not have the pr= ocess of store and restore the added key parameters. Not only i40e but also other PMD code. So, in th= e function pointed to by dev_reset, we add specific function do store and restore of some of the important par= ameters listed above. >=20 > > > > Maybe , I should add this explanation in the patch comments or > > > > function > > > comments? > > > > > > Yes it must be explain in the doxygen part of the function. > > > > Yes, I have add that explanation in v5 which has been commit to dpdk.or= g.