DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Wiles, Roger Keith" <keith.wiles@windriver.com>
To: Peter Chen <peter.feifan.chen@gmail.com>
Cc: "<dev@dpdk.org>" <dev@dpdk.org>
Subject: Re: [dpdk-dev] Sending & Receiving Packets
Date: Mon, 24 Jun 2013 05:03:11 +0000	[thread overview]
Message-ID: <CED3AAF9-FD13-441C-9A83-145F3E0EBB7F@windriver.com> (raw)
In-Reply-To: <CAMGYKAeMQWi1BoynR643_o5ba6p8yhXa_6fQ4XT-ACpc-fFdDg@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1749 bytes --]

Hi Peter,

When DPDK is running on the server it takes control of the ports, which means the network stack that would answer a ping (ICMP Echo) would not be attached to the port any more. You would have to add code to DPDK as an application to receive the ICMP Echo packet and respond with a ICMP Reply packet. The other method would be to attach a network stack as the application to DPDK and use that network stack to receive and send packets.

Writing a simple DPDK application to receive packets off the ports and look for ICMP Echo request and to respond with a ICMP Echo reply is not that hard as I do that work in Pktgen. If you want to do more then just grab packets and determine if you need to send out a packet you would need to port some stack on top of DPDK like lwIP. You can this other ways, but it would take a bit more text to describe.

Have a look at Pktgen on GitHub and you can look at that code for a basic example.

Thank you, ++Keith
-------------------------------
Keith Wiles
Principal Technologist for Networking
cell 972-213-5533
Wind River Systems






On Jun 23, 2013, at 11:52 PM, Peter Chen <peter.feifan.chen@gmail.com<mailto:peter.feifan.chen@gmail.com>>
 wrote:

I was wondering how I can send/receive packets from my computer to my server which has dpdk running. Since what seems to happen is that dpdk binds to the ethernet device, what would be its IP address?

For example how would I send a ping from one computer to my server with dpdk binded to the NIC?

Would I send a packet with only MAC address and dpdk binded NIC would pick it up and move the packet up to dpdk and then to the user space? Just kind of confused how that works. I would be grateful for any help!

Peter


[-- Attachment #2: Type: text/html, Size: 2854 bytes --]

  reply	other threads:[~2013-06-24  5:03 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-24  4:52 Peter Chen
2013-06-24  5:03 ` Wiles, Roger Keith [this message]
     [not found]   ` <CAMGYKAfYt3xyZj-Np6bsgydGHW_FKv81ZxODFG0_+U+KohQZig@mail.gmail.com>
2013-06-24 14:12     ` Wiles, Roger Keith
2014-01-20 18:31 Sharma, RishiX
2014-01-20 19:08 ` Wiles, Roger Keith

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CED3AAF9-FD13-441C-9A83-145F3E0EBB7F@windriver.com \
    --to=keith.wiles@windriver.com \
    --cc=dev@dpdk.org \
    --cc=peter.feifan.chen@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).