From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id A56D758D3 for ; Tue, 17 Jun 2014 11:00:15 +0200 (CEST) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga103.fm.intel.com with ESMTP; 17 Jun 2014 01:55:24 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.01,492,1400050800"; d="scan'208";a="549089059" Received: from irsmsx101.ger.corp.intel.com ([163.33.3.153]) by fmsmga001.fm.intel.com with ESMTP; 17 Jun 2014 01:57:05 -0700 Received: from irsmsx107.ger.corp.intel.com (163.33.3.99) by IRSMSX101.ger.corp.intel.com (163.33.3.153) with Microsoft SMTP Server (TLS) id 14.3.123.3; Tue, 17 Jun 2014 09:57:04 +0100 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.239]) by IRSMSX107.ger.corp.intel.com ([169.254.10.208]) with mapi id 14.03.0123.003; Tue, 17 Jun 2014 09:57:04 +0100 From: "Ananyev, Konstantin" To: David Marchand , "dev@dpdk.org" Thread-Topic: [PATCH v2 0/7] add mtu and flow control handlers Thread-Index: AQHPhwy3DNZ+AHlmXEexeQr1GYA9WZtz+DGggAD49gCAABKmUA== Date: Tue, 17 Jun 2014 08:57:03 +0000 Message-ID: <2601191342CEEE43887BDE71AB9772580EFB75F6@IRSMSX105.ger.corp.intel.com> References: <1402666663-10260-1-git-send-email-david.marchand@6wind.com> <2601191342CEEE43887BDE71AB9772580EFB73D4@IRSMSX105.ger.corp.intel.com> <539FFF5A.80307@6wind.com> In-Reply-To: <539FFF5A.80307@6wind.com> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.180] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v2 0/7] add mtu and flow control handlers 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: Tue, 17 Jun 2014 09:00:16 -0000 Hi David, >> >> 1) [PATCH v2 3/7] ethdev: store min rx buffer size >> @@ -879,6 +879,8 @@ rte_eth_rx_queue_setup(uint8_t port_id, uint16_t rx_= queue_id, >> const struct rte_eth_rxconf *rx_conf, >> struct rte_mempool *mp) >> { >> ... >> + if (!ret) { >> + if (dev->data->min_rx_buf_size > mbp_buf_size) >> + dev->data->min_rx_buf_size =3D mbp_buf_size; >> + } >> + >> + return ret; >> >> Where do you set the initial value of min_rx_buf_size? >> Can't find it by some reason. >Hum, actually, dev->data structure is supposed to be set to 0 at init=20 >time or I missed something. >I would say this happens once for the whole rte_eth_dev_data array in=20 >rte_eth_dev_data_alloc() in primary process (first call to=20 >rte_eth_dev_allocate()). Yes, I understand that it will be initialised to 0 together with whole dev-= >data. But then, the condition: if (dev->data->min_rx_buf_size > mbp_buf_size) would never be true, and min_rx_buf_size would always remain 0? I thought you need to initialise it with UINT32_MAX(or UINT16_MAX). BTW, not big deal, but I think uint16_t is enough for min_rx_buf_size. >> >> 3) if ((mtu < 68) || (frame_size > dev_info.max_rx_pktlen)) >> Can we add a new define for min allowable MTU (68) as it used in few pla= ces. >RTE_IPV4_MIN_MTU then ? Sounds good to me. >I am not sure where this belongs, it could go in rte_ethdev.h. Probably rte_ether.h? Konstantin