From: John Fastabend <john.fastabend@gmail.com>
To: bblanco@plumgrid.com, john.fastabend@gmail.com,
alexei.starovoitov@gmail.com, jeffrey.t.kirsher@intel.com,
brouer@redhat.com, davem@davemloft.net
Cc: xiyou.wangcong@gmail.com, intel-wired-lan@lists.osuosl.org,
u9012063@gmail.com, netdev@vger.kernel.org
Subject: [net-next PATCH v3 1/3] e1000: track BQL bytes regardless of skb or not
Date: Mon, 12 Sep 2016 15:13:27 -0700 [thread overview]
Message-ID: <20160912221327.5610.74333.stgit@john-Precision-Tower-5810> (raw)
In-Reply-To: <20160912220312.5610.77528.stgit@john-Precision-Tower-5810>
The BQL API does not reference the sk_buff nor does the driver need to
reference the sk_buff to calculate the length of a transmitted frame.
This patch removes an sk_buff reference from the xmit irq path and
also allows packets sent from XDP to use BQL.
Signed-off-by: John Fastabend <john.r.fastabend@intel.com>
---
drivers/net/ethernet/intel/e1000/e1000_main.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/drivers/net/ethernet/intel/e1000/e1000_main.c b/drivers/net/ethernet/intel/e1000/e1000_main.c
index f42129d..62a7f8d 100644
--- a/drivers/net/ethernet/intel/e1000/e1000_main.c
+++ b/drivers/net/ethernet/intel/e1000/e1000_main.c
@@ -3882,11 +3882,8 @@ static bool e1000_clean_tx_irq(struct e1000_adapter *adapter,
if (cleaned) {
total_tx_packets += buffer_info->segs;
total_tx_bytes += buffer_info->bytecount;
- if (buffer_info->skb) {
- bytes_compl += buffer_info->skb->len;
- pkts_compl++;
- }
-
+ bytes_compl += buffer_info->length;
+ pkts_compl++;
}
e1000_unmap_and_free_tx_resource(adapter, buffer_info);
tx_desc->upper.data = 0;
next prev parent reply other threads:[~2016-09-12 22:13 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-12 22:13 [net-next PATCH v3 0/3] e1000 XDP implementation John Fastabend
2016-09-12 22:13 ` John Fastabend [this message]
2016-09-13 3:00 ` [Intel-wired-lan] [net-next PATCH v3 1/3] e1000: track BQL bytes regardless of skb or not Alexander Duyck
2016-09-13 4:25 ` Tom Herbert
2016-09-13 13:17 ` Alexander Duyck
2016-09-14 23:57 ` Brown, Aaron F
2016-09-15 0:43 ` Alexei Starovoitov
2016-09-15 4:22 ` John Fastabend
2016-09-15 23:29 ` Brown, Aaron F
2016-09-12 22:13 ` [net-next PATCH v3 2/3] e1000: add initial XDP support John Fastabend
2016-09-12 22:46 ` Eric Dumazet
2016-09-12 23:07 ` Alexei Starovoitov
2016-09-12 23:46 ` Eric Dumazet
2016-09-13 0:03 ` Tom Herbert
2016-09-13 1:28 ` Alexei Starovoitov
2016-09-13 16:21 ` Tom Herbert
2016-09-13 17:13 ` Alexei Starovoitov
2016-09-13 17:37 ` Eric Dumazet
2016-09-13 17:59 ` Alexei Starovoitov
2016-09-13 18:28 ` [Intel-wired-lan] " Rustad, Mark D
2016-09-13 18:30 ` Alexei Starovoitov
2016-09-13 19:14 ` Rustad, Mark D
2016-09-13 21:52 ` Alexei Starovoitov
2016-09-13 22:41 ` Rustad, Mark D
2016-09-13 23:40 ` Alexei Starovoitov
2016-09-14 0:13 ` Rustad, Mark D
2016-09-14 23:42 ` Brown, Aaron F
2016-09-13 23:17 ` Francois Romieu
2016-09-13 17:55 ` Tom Herbert
2016-09-13 1:21 ` Alexei Starovoitov
2016-09-18 17:25 ` Jesper Dangaard Brouer
2016-09-13 3:42 ` [Intel-wired-lan] " Alexander Duyck
2016-09-13 16:56 ` Alexei Starovoitov
2016-09-12 22:14 ` [net-next PATCH v3 3/3] e1000: bundle xdp xmit routines John Fastabend
2016-09-12 23:45 ` Tom Herbert
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=20160912221327.5610.74333.stgit@john-Precision-Tower-5810 \
--to=john.fastabend@gmail.com \
--cc=alexei.starovoitov@gmail.com \
--cc=bblanco@plumgrid.com \
--cc=brouer@redhat.com \
--cc=davem@davemloft.net \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=jeffrey.t.kirsher@intel.com \
--cc=netdev@vger.kernel.org \
--cc=u9012063@gmail.com \
--cc=xiyou.wangcong@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