netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rasesh Mody <rmody@brocade.com>
To: <davem@davemloft.net>
Cc: <netdev@vger.kernel.org>,
	<adapter_linux_open_src_team@Brocade.COM>,
	Rasesh Mody <rmody@Brocade.COM>
Subject: [net-next 06/12] bna: RX Processing and Config Changes
Date: Tue, 10 Dec 2013 23:00:45 -0800	[thread overview]
Message-ID: <1386745251-13710-7-git-send-email-rmody@brocade.com> (raw)
In-Reply-To: <1386745251-13710-1-git-send-email-rmody@brocade.com>

Change Details:
 - Prefetch header in GRO path. This reduces napi_frags_skb time from 9% to 5%.
 - Changed the configurable limit of RxQ depth to 16384 (was 2048).
 - bnad_rx_unmap_q elements are cachealigned.

Signed-off-by: Rasesh Mody <rmody@brocade.com>
---
 drivers/net/ethernet/brocade/bna/bnad.c | 5 +++++
 drivers/net/ethernet/brocade/bna/bnad.h | 6 +++---
 2 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/brocade/bna/bnad.c b/drivers/net/ethernet/brocade/bna/bnad.c
index 5a3abdb..508f5fc 100644
--- a/drivers/net/ethernet/brocade/bna/bnad.c
+++ b/drivers/net/ethernet/brocade/bna/bnad.c
@@ -540,6 +540,11 @@ bnad_cq_setup_skb_frags(struct bna_rcb *rcb, struct sk_buff *skb,
 
 	unmap_q = rcb->unmap_q;
 	bnad = rcb->bnad;
+
+	/* prefetch header */
+	prefetch(page_address(unmap_q->unmap[sop_ci].page) +
+			unmap_q->unmap[sop_ci].page_offset);
+
 	for (vec = 1, ci = sop_ci; vec <= nvecs; vec++) {
 		unmap = &unmap_q->unmap[ci];
 		BNA_QE_INDX_INC(ci, rcb->q_depth);
diff --git a/drivers/net/ethernet/brocade/bna/bnad.h b/drivers/net/ethernet/brocade/bna/bnad.h
index ce8867d..7a8d733 100644
--- a/drivers/net/ethernet/brocade/bna/bnad.h
+++ b/drivers/net/ethernet/brocade/bna/bnad.h
@@ -84,7 +84,7 @@ struct bnad_rx_ctrl {
 #define BNAD_IOCETH_TIMEOUT	     10000
 
 #define BNAD_MIN_Q_DEPTH		512
-#define BNAD_MAX_RXQ_DEPTH		2048
+#define BNAD_MAX_RXQ_DEPTH		16384
 #define BNAD_MAX_TXQ_DEPTH		2048
 
 #define BNAD_JUMBO_MTU			9000
@@ -237,9 +237,9 @@ struct bnad_rx_vector {
 
 struct bnad_rx_unmap {
 	struct page		*page;
-	u32			page_offset;
 	struct sk_buff		*skb;
 	struct bnad_rx_vector	vector;
+	u32			page_offset;
 };
 
 enum bnad_rxbuf_type {
@@ -257,7 +257,7 @@ struct bnad_rx_unmap_q {
 	int			alloc_order;
 	u32			map_size;
 	enum bnad_rxbuf_type	type;
-	struct bnad_rx_unmap	unmap[0];
+	struct bnad_rx_unmap	unmap[0] ____cacheline_aligned;
 };
 
 #define BNAD_PCI_DEV_IS_CAT2(_bnad) \
-- 
1.8.2.3

  parent reply	other threads:[~2013-12-11  7:01 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-12-11  7:00 [net-next 00/12] bna: Update the Driver to v3.2.23.0 Rasesh Mody
2013-12-11  7:00 ` [net-next 01/12] bna: Add software timestamping support Rasesh Mody
2013-12-11  7:00 ` [net-next 02/12] bna: Set Get IOC fw State Rasesh Mody
2013-12-11  7:00 ` [net-next 03/12] bna: Fix Filter Add Del Rasesh Mody
2013-12-11  7:00 ` [net-next 04/12] bna: RX Filter Enhancements Rasesh Mody
2013-12-11  7:00 ` [net-next 05/12] bna: Enable Multi Buffer RX Rasesh Mody
2013-12-11 17:27   ` David Miller
2013-12-12 16:04     ` Rasesh Mody
2013-12-11  7:00 ` Rasesh Mody [this message]
2013-12-11  7:00 ` [net-next 07/12] bna: CQ Read Fix Rasesh Mody
2013-12-11  7:00 ` [net-next 08/12] bna: Add NULL Check Before Dereferencing TCB Rasesh Mody
2013-12-11  7:00 ` [net-next 09/12] bna: Handle the TX Setup Failures Rasesh Mody
2013-12-11  7:00 ` [net-next 10/12] bna: Embed SKB Length in TX Vector Rasesh Mody
2013-12-11  7:00 ` [net-next 11/12] bna: Firmware Patch Simplification Rasesh Mody
2013-12-11  7:00 ` [net-next 12/12] bna: Update the Driver Version to 3.2.23.0 Rasesh Mody
  -- strict thread matches above, loose matches on Subject: below --
2013-12-13  1:54 [net-next 00/12] bna: Update the Driver to v3.2.23.0 Rasesh Mody
2013-12-13  1:54 ` [net-next 06/12] bna: RX Processing and Config Changes Rasesh Mody
2013-12-18  1:07 [net-next 00/12] bna: Update the Driver to v3.2.23.0 Rasesh Mody
2013-12-18  1:07 ` [net-next 06/12] bna: RX Processing and Config Changes Rasesh Mody

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=1386745251-13710-7-git-send-email-rmody@brocade.com \
    --to=rmody@brocade.com \
    --cc=adapter_linux_open_src_team@Brocade.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).