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 D13255952 for ; Sun, 4 Jan 2015 09:38:19 +0100 (CET) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga103.jf.intel.com with ESMTP; 04 Jan 2015 00:35:07 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.04,691,1406617200"; d="scan'208";a="507197544" Received: from pgsmsx107.gar.corp.intel.com ([10.221.44.105]) by orsmga003.jf.intel.com with ESMTP; 04 Jan 2015 00:32:46 -0800 Received: from shsmsx104.ccr.corp.intel.com (10.239.4.70) by PGSMSX107.gar.corp.intel.com (10.221.44.105) with Microsoft SMTP Server (TLS) id 14.3.195.1; Sun, 4 Jan 2015 16:37:15 +0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.216]) by SHSMSX104.ccr.corp.intel.com ([169.254.5.182]) with mapi id 14.03.0195.001; Sun, 4 Jan 2015 16:37:15 +0800 From: "Ouyang, Changchun" To: Vlad Zolotarov , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH v4 2/6] ixgbe: Negotiate VF API version Thread-Index: AQHQJ+7BMrN9GIeNFkqx4UaILPJ7mJyvGliAgAABEICAAIc3YA== Date: Sun, 4 Jan 2015 08:37:14 +0000 Message-ID: References: <1419398584-19520-1-git-send-email-changchun.ouyang@intel.com> <1420355937-18484-1-git-send-email-changchun.ouyang@intel.com> <1420355937-18484-3-git-send-email-changchun.ouyang@intel.com> <54A8F93F.4080402@cloudius-systems.com> <54A8FA23.1090802@cloudius-systems.com> In-Reply-To: <54A8FA23.1090802@cloudius-systems.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: 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 v4 2/6] ixgbe: Negotiate VF API version X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 Jan 2015 08:38:20 -0000 Hi Vlad, > -----Original Message----- > From: Vlad Zolotarov [mailto:vladz@cloudius-systems.com] > Sent: Sunday, January 4, 2015 4:30 PM > To: Ouyang, Changchun; dev@dpdk.org > Subject: Re: [dpdk-dev] [PATCH v4 2/6] ixgbe: Negotiate VF API version >=20 >=20 > On 01/04/15 10:26, Vlad Zolotarov wrote: > > > > On 01/04/15 09:18, Ouyang Changchun wrote: > >> Negotiate API version with VF when receiving the > >> IXGBE_VF_API_NEGOTIATE message. > >> > >> Signed-off-by: Changchun Ouyang > > > > Reviewed-by: Vlad Zolotarov Thanks for your reviewing. >=20 > One small remark below. >=20 > > > >> --- > >> lib/librte_pmd_ixgbe/ixgbe_ethdev.h | 1 + > >> lib/librte_pmd_ixgbe/ixgbe_pf.c | 25 +++++++++++++++++++++++++ > >> 2 files changed, 26 insertions(+) > >> > >> diff --git a/lib/librte_pmd_ixgbe/ixgbe_ethdev.h > >> b/lib/librte_pmd_ixgbe/ixgbe_ethdev.h > >> index ca99170..730098d 100644 > >> --- a/lib/librte_pmd_ixgbe/ixgbe_ethdev.h > >> +++ b/lib/librte_pmd_ixgbe/ixgbe_ethdev.h > >> @@ -159,6 +159,7 @@ struct ixgbe_vf_info { > >> uint16_t tx_rate[IXGBE_MAX_QUEUE_NUM_PER_VF]; > >> uint16_t vlan_count; > >> uint8_t spoofchk_enabled; > >> + uint8_t api_version; > >> }; > >> /* > >> diff --git a/lib/librte_pmd_ixgbe/ixgbe_pf.c > >> b/lib/librte_pmd_ixgbe/ixgbe_pf.c index 51da1fd..495aff5 100644 > >> --- a/lib/librte_pmd_ixgbe/ixgbe_pf.c > >> +++ b/lib/librte_pmd_ixgbe/ixgbe_pf.c > >> @@ -469,6 +469,28 @@ ixgbe_set_vf_lpe(struct rte_eth_dev *dev, > >> __rte_unused uint32_t vf, uint32_t *ms > >> } > >> static int > >> +ixgbe_negotiate_vf_api(struct rte_eth_dev *dev, uint32_t vf, > >> uint32_t *msgbuf) > >> +{ > >> + uint32_t api_version =3D msgbuf[1]; > >> + struct ixgbe_vf_info *vfinfo =3D > >> + *IXGBE_DEV_PRIVATE_TO_P_VFDATA(dev->data->dev_private); > >> + > >> + switch (api_version) { > >> + case ixgbe_mbox_api_10: > >> + case ixgbe_mbox_api_11: >=20 > Why version 2.0 is not negotiated? >=20 Because it doesn't fully support 2.0 features yet. Thanks Changchun