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 750D64A63 for ; Wed, 9 Mar 2016 17:44:37 +0100 (CET) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga101.fm.intel.com with ESMTP; 09 Mar 2016 08:44:17 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.24,311,1455004800"; d="scan'208";a="920282669" Received: from rhorton-mobl.ger.corp.intel.com (HELO [163.33.229.61]) ([163.33.229.61]) by fmsmga001.fm.intel.com with ESMTP; 09 Mar 2016 08:44:10 -0800 Message-ID: <56E052DA.8000901@intel.com> Date: Wed, 09 Mar 2016 16:44:10 +0000 From: Remy Horton Organization: Intel Shannon Limited User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.7.0 MIME-Version: 1.0 To: Vivek Gupta References: <488FF59D9020184C9DCF4B4A0DA4781425535B44@NDA-HCLT-MBS03.hclt.corp.hcl.in> In-Reply-To: <488FF59D9020184C9DCF4B4A0DA4781425535B44@NDA-HCLT-MBS03.hclt.corp.hcl.in> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Cc: dev@dpdk.org Subject: Re: [dpdk-dev] Client Server Application using DPDK API 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, 09 Mar 2016 16:44:37 -0000 'noon, On 09/03/2016 08:45, Vivek Gupta wrote: > Hi > > I want to write a Client Server application using DPDK API on a > single machine. What are the basic building block for that. How can > we write such application? examples/l2fwd/main.c and examples/ethtool/ethtool-app/main.c are probably the easier examples to follow. In terms of function calls, it is pretty much: rte_eal_init(..); for (each port) { rte_pktmbuf_pool_create(..); rte_eth_dev_configure(..); rte_eth_dev_rx_queue_setup(..); rte_eth_dev_tx_queue_setup(..); rte_eth_dev_start(..); } while(1) { rte_eth_rx_burst(..); /* incoming frames */ rte_eth_tx_burst(..); /* outgoing frames */ } Bear in mind that DPDK deals with MAC frames rather than higher level IP packets, which may be an issue if you intend to use TCP/IP based application protocols. > ::DISCLAIMER:: Avoid using confidentality disclaimers on mailing list emails. It tends to "annoy" people.. :) Regards, ..Remy