From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-oi0-f47.google.com (mail-oi0-f47.google.com [209.85.218.47]) by dpdk.org (Postfix) with ESMTP id B77F42986 for ; Fri, 11 Mar 2016 21:54:51 +0100 (CET) Received: by mail-oi0-f47.google.com with SMTP id c203so94775047oia.2 for ; Fri, 11 Mar 2016 12:54:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc; bh=3t6whxv2FFhAxvommzy7JbcRkHQiBt0/l3e/j+yRVow=; b=YZ1dmtlD5HCVnz7aUIDd4iklpjVz3uwIvv4WYx5B59mssG7oLCnQB3ghDHpdY9Cp19 E8UOR1yyoefaqUkciq3D+lNy9yWMhdB8zT9y3/0+G9QDi0MgxgROsZketc95xld7W+c9 GyA0qhS9/u4hUCqTYuflZiD1yrp3rTHFTv9SEyS0jyukBjXj2NDvr1yBFnF8pdyNxEGW k7btsvWXk4c6qv2h0JuxkR2U1yOGVG3UQCoL8t+R4eLXk+AAmxQOCcY0QMPBmQ3EWMTq 8I7dNOFDj7JHSVnXOc7Et3fjKIeEAtXZuqPd50ISq4qUy45Logi9VUTOW1sy4MxTgIHh qVnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc; bh=3t6whxv2FFhAxvommzy7JbcRkHQiBt0/l3e/j+yRVow=; b=RY4bs22G7Kc3wiycXVboQPEBUefoI1sikBMYbRNe3iaQS9DKJruzc9PP5c4EtWfYPU h5cackxAhVZKI+ED3weVXQXyAS8266jyhzD0MavDFYHqlhtuQBCVjjJANcjeJu2ggUch /RDwUmPKgBcQjDqjB7qRZia/A6spR+95KVkTcjqwMZfRialjTHhG0OuZX+7x1bvLyx2v 6uMX+jLoByMCPH7obt0SJBtdhwON75lkaQkFDzdUCodsSeBD/cOumVqdSXBwnRMVJlMU 4dn/ELDabpsk/oDxe4U8aPo8nPuF6PV45phOjgptixDv/RbO6bN2yn/r8kiIJs5onvbQ 9aew== X-Gm-Message-State: AD7BkJL6WMSqDBe/wiEdTtCnaqMCSU8rTGBF0GmGQCcJBOHR/3QoroLzyawfZdIrowccgobjCxr9d4DpqEvFJA== MIME-Version: 1.0 X-Received: by 10.202.214.21 with SMTP id n21mr6741162oig.122.1457729691226; Fri, 11 Mar 2016 12:54:51 -0800 (PST) Received: by 10.76.68.7 with HTTP; Fri, 11 Mar 2016 12:54:51 -0800 (PST) In-Reply-To: References: Date: Fri, 11 Mar 2016 15:54:51 -0500 Message-ID: From: Kyle Larose To: Mahdi Moradmand Badie Content-Type: text/plain; charset=UTF-8 Cc: users@dpdk.org Subject: Re: [dpdk-users] Send and Receive packets to/from specific core 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, 11 Mar 2016 20:54:52 -0000 On Fri, Mar 11, 2016 at 3:47 PM, Mahdi Moradmand Badie wrote: > My big challenge is having a tested code (run able with right > functionality), then run and change it in order to have my task. > I wanna use the share memory btw cores in order to write/read to/from and > knowing how do that :), all available code which I found are based on NIC :( > or maybe I am wrong!!! > Thanks in advance, Take a look at this example: http://dpdk.org/doc/guides/sample_app_ug/multi_process.html#basic-multi-process-example IIRC, it uses rings to send messages back and forth between the cores. The code is available with the dpdk source, so it should serve as a good starting point to see how to set up the shared memory and use it. Does that help? > > On 11 March 2016 at 15:43, Kyle Larose wrote: >> >> On Fri, Mar 11, 2016 at 3:22 PM, Mahdi Moradmand Badie >> wrote: >> > Dear All, >> > >> > I wanna Send(write) a Packet(s) with specific data (for example x = 10) >> > from core 0 to share memory and Receive (Read) it with another Core (for >> > example Core 1), change it in Core 1 (for example X = X + 1) and write >> > again in share memory. >> > I really don't know How I could do it, I wanna do this without using NIC >> > ot >> > rte_eth at all, so simple and easy but I confused. >> > Please help me. >> > >> > PS. I know there are many example do more complex than this small >> > exercise >> > but all did it via NIC. >> >> What is your biggest challenge? Is it moving information between >> cores, or getting information into your application? >> >> Consider that most of the multiprocess examples in DPDK do two things: >> 1) Send/Receive packets to/from a NIC >> 2) Send packets between cores >> >> You obviously want to do #2, and looking at those examples should make >> how to do it fairly obvious. Is your challenge replacing #1 with >> something other than a NIC? If so, you *could* consider using a pcap >> PMD to just read packets from a file. In the past, I have used ring >> PMDs in conjunction with a secondary process which generates packets >> to inject arbitrarily formatted packets into my program. >> >> > >> > -- >> > M@hdi Mor@dm@nd B@die > > > > > -- > M@hdi Mor@dm@nd B@die