DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Sanford, Robert" <rsanford@akamai.com>
To: "Richardson, Bruce" <bruce.richardson@intel.com>,
	Thomas Monjalon <thomas.monjalon@6wind.com>,
	"dev@dpdk.org" <dev@dpdk.org>
Subject: [dpdk-dev] Ethernet API - multiple post-RX-burst callbacks' run-order is opposite to their add-order
Date: Thu, 2 Jul 2015 21:04:48 +0000	[thread overview]
Message-ID: <D1BB0052.A7DB%rsanford@akamai.com> (raw)

When one adds multiple post-RX-burst callbacks to a queue, their execution order is the opposite of the order in which they are added. For example, we add callback A( ), and then we add callback B( ). When we call rte_eth_rx_burst, after invoking the device's rx_pkt_burst function, it will invoke B( ), and then A( ). The same goes for pre-TX-burst callbacks, too.

This is counter-intuitive. Shouldn't we either execute the callbacks in the same order that we add them (by changing the internals of the add-APIs), or change the add-APIs to allow one to specify whether a callback is added to the head or tail of the callback list? At the least, we could document the expected behavior.
Any thoughts on this?

--
Regards,
Robert

             reply	other threads:[~2015-07-02 21:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-07-02 21:04 Sanford, Robert [this message]
2015-07-03  9:57 ` Bruce Richardson
2015-07-03 10:02   ` Thomas Monjalon
2015-07-10 13:14 ` Mcnamara, John
2015-07-10 13:24   ` Thomas Monjalon
2015-07-10 13:52     ` Mcnamara, John
2015-07-10 14:02       ` Thomas Monjalon

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=D1BB0052.A7DB%rsanford@akamai.com \
    --to=rsanford@akamai.com \
    --cc=bruce.richardson@intel.com \
    --cc=dev@dpdk.org \
    --cc=thomas.monjalon@6wind.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).