All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen-OTpzqLSitTUnbdJkjeBofR2eb7JE58TQ@public.gmane.org>
To: Thomas Monjalon
	<thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org>
Cc: dev-VfR2kkLFssw@public.gmane.org,
	Stephen Hemminger
	<shemming-43mecJUBy8ZBDgjK7y7TUQ@public.gmane.org>
Subject: Re: [PATCH] ixgbe: do not include CRC in Tx byte count
Date: Tue, 27 Jan 2015 11:38:47 +0000	[thread overview]
Message-ID: <20150127113847.3d4d32a0@uryu.home.lan> (raw)
In-Reply-To: <7916082.1WV7FdSlI3@xps13>

On Tue, 27 Jan 2015 11:11:39 +0100
Thomas Monjalon <thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.org> wrote:

> Hi Stephen,
> 
> 2015-01-22 22:23, stephen-OTpzqLSitTUnbdJkjeBofR2eb7JE58TQ@public.gmane.org:
> > From: Stephen Hemminger <shemming-43mecJUBy8ZBDgjK7y7TUQ@public.gmane.org>
> > 
> > The ixgbe driver was including CRC in the transmit packet byte
> > count, but not for packets received. This was notice when forwarding and
> > the number of bytes received was greater than the number of bytes transmitted
> 
> Tx includes CRC and Rx count is greater, really?
> 
> > for the same number of packets. Make the driver behave like other
> > virtual devices and not include CRC in byte count. Use the same queue
> > counters already computed and used for Rx.
> 
> Please could you describe the difference between gptc/gotc and qptc/qbtc?
> 
> Thank you


The byte counts for global registers include CRC in the byte count.
This has been observed by experimentation and validated by QA and documented
in Intel HW specs.

The original code used queue counts for Rx because the global counters
include missed packets (which must not be included in the ipacket counts).
I suspect that is why the original developer used the queue counts, as
a good side effect the Rx byte count was correct (no CRC). I just extended
this for Tx.

  reply	other threads:[~2015-01-27 11:38 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-23  6:23 [PATCH] ixgbe: do not include CRC in Tx byte count stephen-OTpzqLSitTUnbdJkjeBofR2eb7JE58TQ
     [not found] ` <1421994224-2127-1-git-send-email-stephen-OTpzqLSitTUnbdJkjeBofR2eb7JE58TQ@public.gmane.org>
2015-01-27 10:11   ` Thomas Monjalon
2015-01-27 11:38     ` Stephen Hemminger [this message]
     [not found]       ` <20150127113847.3d4d32a0-CA4OZQ/Yy2Lykuyl+CZolw@public.gmane.org>
2015-03-04 20:55         ` Thomas Monjalon
     [not found]       ` <9265c0d3b03e4f33b7823139be7b3b91@BRMWP-EXMB11.corp.brocade.com>
     [not found]         ` <9265c0d3b03e4f33b7823139be7b3b91-sI283RzA5cMA50eAn2D9H4CDckiq/fhJZeezCHUQhQ4@public.gmane.org>
2015-03-04 23:06           ` Stephen Hemminger
2015-03-23 14:08   ` Thomas Monjalon
2015-03-23 16:45   ` Ananyev, Konstantin
     [not found]     ` <2601191342CEEE43887BDE71AB9772582140700B-pww93C2UFcwu0RiL9chJVbfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2015-03-24 15:55       ` Stephen Hemminger
2015-04-02 20:20         ` Butler, Siobhan A
2015-03-24 23:54 Ananyev, Konstantin
     [not found] ` <2601191342CEEE43887BDE71AB977258214074F6-pww93C2UFcwu0RiL9chJVbfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2015-04-01  7:45   ` Thomas Monjalon
2015-07-09 23:03     ` Stephen Hemminger
     [not found] ` <c8d4fd5c400c4beaa4577b8b1069fe04@BRMWP-EXMB12.corp.brocade.com>
     [not found]   ` <c8d4fd5c400c4beaa4577b8b1069fe04-sI283RzA5cNU5qdSg20wvYCDckiq/fhJZeezCHUQhQ4@public.gmane.org>
2015-04-01 18:36     ` Stephen Hemminger
2015-07-09 22:59       ` 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=20150127113847.3d4d32a0@uryu.home.lan \
    --to=stephen-otpzqlsittunbdjkjebofr2eb7je58tq@public.gmane.org \
    --cc=dev-VfR2kkLFssw@public.gmane.org \
    --cc=shemming-43mecJUBy8ZBDgjK7y7TUQ@public.gmane.org \
    --cc=thomas.monjalon-pdR9zngts4EAvxtiuMwx3w@public.gmane.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.