From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id CC10B688C for ; Wed, 10 Sep 2014 03:24:00 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga101.fm.intel.com with ESMTP; 09 Sep 2014 18:29:06 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.04,494,1406617200"; d="scan'208";a="588921919" Received: from fmsmsx103.amr.corp.intel.com ([10.18.124.201]) by fmsmga001.fm.intel.com with ESMTP; 09 Sep 2014 18:29:05 -0700 Received: from fmsmsx114.amr.corp.intel.com (10.18.116.8) by FMSMSX103.amr.corp.intel.com (10.18.124.201) with Microsoft SMTP Server (TLS) id 14.3.195.1; Tue, 9 Sep 2014 18:29:01 -0700 Received: from shsmsx102.ccr.corp.intel.com (10.239.4.154) by FMSMSX114.amr.corp.intel.com (10.18.116.8) with Microsoft SMTP Server (TLS) id 14.3.195.1; Tue, 9 Sep 2014 18:29:00 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.230]) by shsmsx102.ccr.corp.intel.com ([169.254.2.192]) with mapi id 14.03.0195.001; Wed, 10 Sep 2014 09:28:56 +0800 From: "Zhang, Helin" To: Sergey Mironov , "dev@dpdk.org" Thread-Topic: [dpdk-dev] [PATCH] igb_ethdev.c: complete switches for i211 NC Thread-Index: AQHPyBtJCF2a513oLk+MfPnjPBt4V5v5nKxA Date: Wed, 10 Sep 2014 01:28:55 +0000 Message-ID: References: <1409819711-18718-1-git-send-email-grrwlf@gmail.com> In-Reply-To: <1409819711-18718-1-git-send-email-grrwlf@gmail.com> Accept-Language: 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] igb_ethdev.c: complete switches for i211 NC 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: Wed, 10 Sep 2014 01:24:01 -0000 > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Sergey Mironov > Sent: Thursday, September 4, 2014 4:35 PM > To: dev@dpdk.org > Subject: [dpdk-dev] [PATCH] igb_ethdev.c: complete switches for i211 NC >=20 > Hi! I have got an update for my "i212 problem". First of all, I found tha= t I have > made a mistake. My controller is named i211, not i212 :) Next, i211 contr= oller is > controlled by the lib_pmd_e1000 driver. > Unfortunately, looks like it's support is pure. For example, igb_ethdev.c > contains function eth_igb_infos_get() which should set number of tx/rx qu= eues > supported by the hardware. It contains huge [switch] but there is no i211= case! > That is why I see zeros every time I try to start this NC. Also, there ar= e few > other places which mention i210, but not mention i211. I've attached a pa= tch > which adds necessary > i211 support, but I didn't check it enough to say it is totally correct. = For now I > see that it just able to send and receive some packets. >=20 > Could you please review/correct it? > --- > lib/librte_pmd_e1000/igb_ethdev.c | 11 +++++++++-- > 1 file changed, 9 insertions(+), 2 deletions(-) >=20 > diff --git a/lib/librte_pmd_e1000/igb_ethdev.c > b/lib/librte_pmd_e1000/igb_ethdev.c > index f93a460..23e638d 100644 > --- a/lib/librte_pmd_e1000/igb_ethdev.c > +++ b/lib/librte_pmd_e1000/igb_ethdev.c > @@ -689,7 +689,8 @@ eth_igb_start(struct rte_eth_dev *dev) > * value of Write-Back Threshold registers. > */ > if ((hw->mac.type =3D=3D e1000_82576) || (hw->mac.type =3D=3D e1000_825= 80) || > - (hw->mac.type =3D=3D e1000_i350) || (hw->mac.type =3D=3D e1000_i210)) = { > + (hw->mac.type =3D=3D e1000_i350) || (hw->mac.type =3D=3D e1000_i210) |= | > + (hw->mac.type =3D=3D e1000_i211)) { > uint32_t ivar; >=20 > /* Enable all RX & TX queues in the IVAR registers */ @@ -837,7 > +838,7 @@ igb_get_rx_buffer_size(struct e1000_hw *hw) > rx_buf_size =3D (E1000_READ_REG(hw, E1000_RXPBS) & 0xf); > rx_buf_size =3D (uint32_t) e1000_rxpbs_adjust_82580(rx_buf_size); > rx_buf_size =3D (rx_buf_size << 10); > - } else if (hw->mac.type =3D=3D e1000_i210) { > + } else if (hw->mac.type =3D=3D e1000_i210 || hw->mac.type =3D=3D e1000_= i211) { > rx_buf_size =3D (E1000_READ_REG(hw, E1000_RXPBS) & 0x3f) << 10; > } else { > rx_buf_size =3D (E1000_READ_REG(hw, E1000_PBA) & 0xffff) << 10; > @@ -1179,6 +1180,12 @@ eth_igb_infos_get(struct rte_eth_dev *dev, > dev_info->max_vmdq_pools =3D 0; > break; >=20 > + case e1000_i211: > + dev_info->max_rx_queues =3D 2; > + dev_info->max_tx_queues =3D 2; > + dev_info->max_vmdq_pools =3D 0; > + break; > + > case e1000_vfadapt: > dev_info->max_rx_queues =3D 2; > dev_info->max_tx_queues =3D 2; > -- > 1.8.4.3 Reviewed-by: Helin Zhang Really good to have this patch of supporting i211! Thank you very much! Regards, Helin