DPDK usage discussions
 help / color / mirror / Atom feed
From: "Wiles, Keith" <keith.wiles@intel.com>
To: "Александр Самойлов" <cidjey1991@mail.ru>,
	"users@dpdk.org" <users@dpdk.org>
Subject: Re: [dpdk-users] Sending packets without memory freeing
Date: Wed, 28 Oct 2015 15:00:20 +0000	[thread overview]
Message-ID: <60B56ED4-042E-40A1-BB9D-30313FC4D3FF@intel.com> (raw)
In-Reply-To: <1446043948.176464639@f208.i.mail.ru>

On 10/28/15, 9:52 AM, "users on behalf of Александр Самойлов" <users-bounces@dpdk.org on behalf of cidjey1991@mail.ru> wrote:

> Hello, I'm developing a TCP reassembler of some sorts based on DPDK. Currently I'm working on TCP segments retransmission (because of time out).
>
>To do so, I've developed the next idea: how about to keep every outgoing packet in a queue and remove them from there when the corresponding ACK has arrived. So the plan is simple: build a packet, push it into the queue, send it, wait for the ACK, remove the packet from the queue. If the retransmission time is out, retransmit the packet.
>
>But this simple plan seems to be impractible, for DPDK frees mbufs when sending packets. So I really have to just copy all the packets before sending them, which is not a good idea, of course.

If you increment the refcnt then you can hold on to the mbuf after the driver frees the packet.
>
>So I've thought that it could be nice to have an opportunity sometimes to send packets without actually freeing mbufs so that we could retransmit them if we have such a need.
>
>P.S. Right now my actual plan is to go to the depths of DPDK, find the sending packets function and modify it a bit so it doesn't free the memory. But I have a suspision that it won't end well :)
>
>P.S.S. Or maybe I'm missing something and there's an opportunity to send packets without freeing the memory after all?
>
>
>


— 
Regards,
++Keith Wiles

Intel Corporation



      reply	other threads:[~2015-10-28 15:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-28 14:52 Александр Самойлов
2015-10-28 15:00 ` Wiles, Keith [this message]

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=60B56ED4-042E-40A1-BB9D-30313FC4D3FF@intel.com \
    --to=keith.wiles@intel.com \
    --cc=cidjey1991@mail.ru \
    --cc=users@dpdk.org \
    /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).