From: Chetan Loke <loke.chetan@gmail.com>
To: davem@davemloft.net, netdev@vger.kernel.org
Cc: Chetan Loke <loke.chetan@gmail.com>
Subject: [PATCH net-next v3 af-packet 0/2] Enhance af-packet to provide (near zero)lossless packet capture functionality.
Date: Sun, 17 Jul 2011 23:26:48 -0400 [thread overview]
Message-ID: <1310959610-1688-1-git-send-email-loke.chetan@gmail.com> (raw)
Changes in v3:
1) Stripped __packed__ attribute. (Dave Miller)
Replaced with aligned_u64 and padding.
2) Added 'feature_request_word'.
3) Added rx_hash field to the v3-header. (Chetan L)
Changes in v2:
1) Aligned bdqc members, pr_err to WARN, sob email (Joe Perches)
2) Added tp_padding (Eric Dumazet)
3) Nuked useless ;) white space (Stephen H)
4) Use __u types in headers (Ben Hutchings)
5) Added field for creating private area (Chetan Loke)
This patch attempts to:
1)Improve network capture visibility by increasing packet density
2)Assist in analyzing multiple(aggregated) capture ports.
Benefits:
B1) ~15-20% reduction in cpu-usage.
B2) ~20% increase in packet capture rate.
B3) ~2x increase in packet density.
B4) Port aggregation analysis.
B5) Non static frame size to capture entire packet payload.
With the current af_packet->rx::mmap based approach, the element size
in the block needs to be statically configured. Nothing wrong with this
config/implementation. But the traffic profile cannot be known in advance.
And so it would be nice if that configuration wasn't static. Normally,
one would configure the element-size to be '2048' so that you can atleast
capture the entire 'MTU-size'.But if the traffic profile varies then we
would end up either i)wasting memory or ii) end up getting a sliced frame.
In other words the packet density will be much less in the first case.
Detailed description of the test-setup etc can be viewed at:
http://thread.gmane.org/gmane.linux.kernel/1158216
Chetan Loke (2):
include/linux/if_packet.h | 125 ++++++
net/packet/af_packet.c | 920 ++++++++++++++++++++++++++++++++++++++++++---
2 files changed, 999 insertions(+), 46 deletions(-)
--
1.7.5.2
next reply other threads:[~2011-07-18 3:27 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-18 3:26 Chetan Loke [this message]
2011-07-18 3:26 ` [PATCH net-next v3 af-packet 1/2] Enhance af-packet to provide (near zero)lossless packet capture functionality Chetan Loke
2011-07-18 6:38 ` Eric Dumazet
2011-07-18 12:49 ` chetan loke
2011-07-18 16:56 ` David Miller
2011-07-18 3:26 ` [PATCH net-next v3 af-packet 2/2] " Chetan Loke
2011-07-18 3:46 ` Joe Perches
2011-07-18 14:55 ` chetan loke
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=1310959610-1688-1-git-send-email-loke.chetan@gmail.com \
--to=loke.chetan@gmail.com \
--cc=davem@davemloft.net \
--cc=netdev@vger.kernel.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).