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 D9A96952 for ; Fri, 29 Apr 2016 15:38:07 +0200 (CEST) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga103.fm.intel.com with ESMTP; 29 Apr 2016 06:38:06 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.24,551,1455004800"; d="scan'208";a="94277164" Received: from irsmsx152.ger.corp.intel.com ([163.33.192.66]) by fmsmga004.fm.intel.com with ESMTP; 29 Apr 2016 06:38:05 -0700 Received: from irsmsx103.ger.corp.intel.com ([169.254.3.12]) by IRSMSX152.ger.corp.intel.com ([169.254.6.15]) with mapi id 14.03.0248.002; Fri, 29 Apr 2016 14:38:05 +0100 From: "Singh, Jasvinder" To: "Wu, Xiaoban" , "users@dpdk.org" Thread-Topic: Questions about IP-PIPELINE Thread-Index: AQHRn8nw8gyBmpAKUEWE4Z7HVbPgTJ+g9DNQ Date: Fri, 29 Apr 2016 13:38:04 +0000 Message-ID: <54CBAA185211B4429112C315DA58FF6DE12930@IRSMSX103.ger.corp.intel.com> References: In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiYjg1MzNiZjctMjdlMS00N2IyLWI2MzUtNWYyZWQxYWVhZDJhIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX0lDIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE1LjkuNi42IiwiVHJ1c3RlZExhYmVsSGFzaCI6Ijh6QVk1ckNoUU1hZ0NaelpJWnAxeWpqVkZ5cElIaHFydGZ6SCszcVluYjA9In0= x-ctpclassification: CTP_IC x-originating-ip: [163.33.239.182] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-users] Questions about IP-PIPELINE X-BeenThere: users@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: usage discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 29 Apr 2016 13:38:08 -0000 Hi Xiaoban, Please see response inline, > -----Original Message----- > From: users [mailto:users-bounces@dpdk.org] On Behalf Of Wu, Xiaoban > Sent: Tuesday, April 26, 2016 4:21 PM > To: users@dpdk.org > Subject: [dpdk-users] Questions about IP-PIPELINE >=20 > Dear DPDK, >=20 >=20 > I am a beginner of DPDK, recently I want to work on IP-PIPELINE. I am rea= ding > the source codes by myself, but I think it could be more efficient if the > following questions can be answered. >=20 >=20 > Question 1: The ip_pipeline.cfg is parsed at runtime, what is the data ty= pe or > structure that stores these information? =20 In ip_ipeline/app.h, "app_params" structure stores all parsed information r= elated to nic ports, software rings between the pipelines and all other con= figuration parameters required for initializing and running the application= . When configuration file is parsed (ip_pipeline/config_parse.c), app_param= s structure fields are populated with the parsed information and validated = using ip_pipeline/config_check.c > Question 2: Suppose the configuration file has been parsed and stored, > where and how these information will start to have effect, like in which > functions, could you please list some of these functions? In ip_pipeline/main.c, all the functions required to launch and run the i= p_pipeline applications are invoked in "main" function. Once the configurat= ion file is parsed and parameters values are checked, application initilisa= tion takes place which involves EAL initialisation (please refer http://dp= dk.org/doc/guides/prog_guide/env_abstraction_layer.html) followed by mempoo= l, hardware(nic)/software (rings) queues initialisation. The commands accepted by all the pipeline modules as well as specific to pi= peline modules are registered. Then pipelines modules are initialised - fir= st, the front end part (CLI commands definitions specific to the pipeline) = of the pipeline modules are initialised. Then, the back-end part of the pi= pelines which performs packet forwarding and handles commands sent from CLI= , is launched on the assigned cores. All routines releted to application in= itialisation are implemented in app_init() routine (ip_pipeline/init.c). =20 > Question 3: If multiple threads (cores) are running at the same time, can > these threads send or receive packets at the same time? If so, are the > packets stored separately in each own TX or RX queue, or merged into a > single data structure? Where are these data structures defined and used, = can > you please list some functions that explicitly involve these data structu= res? > And moreover, which functions are used to send or receive the packets? Depending upon the application, different cores can be pinned to different = queues of the network interface port and they can receive and transmit pack= ets in parallel. For more details, in addition to abovementioned files, re= fer- lib/librte_port and lib/rte_pipeline libraries. =20 > Some other unrelated questions, but they could help me see the picture Please try to put questions related to different topics on separate emails = so that folks can get an idea from subject line and quickly respond to them= . =20 =20 > Question 4: What is igb-uio driver? What is the purpose of binding the NI= C > with igb-uio driver? To understand the need of binding igb_uio to DPDK application, please refer= link below, http://dpdk.org/doc/guides-2.2/linux_gsg/build_dpdk.html#loading-modules-to= -enable-userspace-io-for-dpdk > Question 5: Does the "hugepage" uses physical memory or physical disk > space? It uses physical memory. On how to reserve hugepages for DPDK applications= ,=20 http://dpdk.org/doc/guides/linux_gsg/sys_reqs.html > Question 6: In the codes, there are both physical address and virtual add= ress > in the struct rte_mbuf, struct rte_memzone, struct rte_memseg. If virtual > address is the memory address like a pointer, what is physical address an= d > what is the usefulness of physical address? The physical addresses refer to addresses in physical memory. These address= es are generally used in direct memory access (DMA) I/O operations as use o= f this mechanism can greatly increase throughput to and from a device. For = more detailed information on this, refer -=20 http://www.oreilly.com/openbook/linuxdrive3/book/ch15.pdf > Thanks so much for your reply and help. >=20 >=20 > All the best, >=20 > Xiaoban >=20 > Thanks, Jasvinder =20