From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by dpdk.org (Postfix) with ESMTP id C5C2B2BA2 for ; Wed, 7 Jun 2017 09:50:32 +0200 (CEST) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga104.jf.intel.com with ESMTP; 07 Jun 2017 00:50:31 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.39,310,1493708400"; d="scan'208";a="111875296" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by fmsmga006.fm.intel.com with ESMTP; 07 Jun 2017 00:50:30 -0700 Received: from fmsmsx114.amr.corp.intel.com (10.18.116.8) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.319.2; Wed, 7 Jun 2017 00:50:30 -0700 Received: from shsmsx152.ccr.corp.intel.com (10.239.6.52) by FMSMSX114.amr.corp.intel.com (10.18.116.8) with Microsoft SMTP Server (TLS) id 14.3.319.2; Wed, 7 Jun 2017 00:50:30 -0700 Received: from shsmsx103.ccr.corp.intel.com ([169.254.4.116]) by SHSMSX152.ccr.corp.intel.com ([169.254.6.122]) with mapi id 14.03.0319.002; Wed, 7 Jun 2017 15:50:28 +0800 From: "Wu, Jingjing" To: "Dai, Wei" , "Lu, Wenzhuo" , "Ananyev, Konstantin" , "Zhang, Helin" CC: "dev@dpdk.org" Thread-Topic: [PATCH 7/7] net/i40e: add support of restoration Thread-Index: AQHS1sOm7sQGM7Bop0u2YOrEPl4JWaIZFzsw Date: Wed, 7 Jun 2017 07:50:27 +0000 Message-ID: <9BB6961774997848B5B42BEC655768F810D9CA6E@SHSMSX103.ccr.corp.intel.com> References: <1495873329-43303-1-git-send-email-wei.dai@intel.com> <1495873329-43303-8-git-send-email-wei.dai@intel.com> In-Reply-To: <1495873329-43303-8-git-send-email-wei.dai@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 10.0.102.7 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 7/7] net/i40e: add support of restoration 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, 07 Jun 2017 07:50:33 -0000 > -----Original Message----- > From: Dai, Wei > Sent: Saturday, May 27, 2017 4:22 PM > To: Lu, Wenzhuo ; Ananyev, Konstantin > ; Zhang, Helin ; Wu,= Jingjing > > Cc: dev@dpdk.org; Dai, Wei > Subject: [PATCH 7/7] net/i40e: add support of restoration >=20 > export dev_uninit and dev_init for restoration to > reset port but keep same port id. >=20 > Signed-off-by: Wei Dai > --- > drivers/net/i40e/i40e_ethdev.c | 2 ++ > drivers/net/i40e/i40e_ethdev_vf.c | 5 +++++ > 2 files changed, 7 insertions(+) >=20 > diff --git a/drivers/net/i40e/i40e_ethdev.c b/drivers/net/i40e/i40e_ethde= v.c > index 4c49673..9512ca4 100644 > --- a/drivers/net/i40e/i40e_ethdev.c > +++ b/drivers/net/i40e/i40e_ethdev.c > @@ -449,6 +449,8 @@ static const struct eth_dev_ops i40e_eth_dev_ops =3D = { > .dev_start =3D i40e_dev_start, > .dev_stop =3D i40e_dev_stop, > .dev_close =3D i40e_dev_close, > + .dev_init =3D eth_i40e_dev_init, > + .dev_uninit =3D eth_i40e_dev_uninit, > .promiscuous_enable =3D i40e_dev_promiscuous_enable, > .promiscuous_disable =3D i40e_dev_promiscuous_disable, > .allmulticast_enable =3D i40e_dev_allmulticast_enable, you can just get int and unint func point by eth_dev->driver.eth_dev_init a= nd eth_dev->driver.eth_dev_init No need to define ops here.