netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Michael Chan <michael.chan@broadcom.com>
To: David Laight <David.Laight@aculab.com>
Cc: Paolo Abeni <pabeni@redhat.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"mchan@broadcom.com" <mchan@broadcom.com>,
	David Miller <davem@davemloft.net>,
	Pavan Chebbi <pavan.chebbi@broadcom.com>
Subject: Re: tg3 dropping packets at high packet rates
Date: Sun, 22 May 2022 16:22:10 -0700	[thread overview]
Message-ID: <CACKFLinYSWgbKL-gtYgqLCkgC9CwqQoDK0tCG_-7Jy+3dfhuww@mail.gmail.com> (raw)
In-Reply-To: <13d6579e9bc44dc2bfb73de8d9715b10@AcuMS.aculab.com>

[-- Attachment #1: Type: text/plain, Size: 1667 bytes --]

On Thu, May 19, 2022 at 1:44 AM David Laight <David.Laight@aculab.com> wrote:
>
> From: Michael Chan
> > Sent: 19 May 2022 01:52
> > Please show a snapshot of all the counters.  In particular,
> > rxbds_empty, rx_discards, etc will show whether the driver is keeping
> > up with incoming RX packets or not.
>
> After running the test for a short time.
> The application stats indicate that around 40000 packets are missing.
>
> # ethtool -S em2 | grep -v ' 0$'; for f in /sys/class/net/em2/statistics/*; do echo $f $(cat $f); done|grep -v ' 0$'
> NIC statistics:
>      rx_octets: 4589028558
>      rx_ucast_packets: 21049866
>      rx_mcast_packets: 763
>      rx_bcast_packets: 746
>      tx_octets: 4344
>      tx_ucast_packets: 6
>      tx_mcast_packets: 40
>      tx_bcast_packets: 3
>      rxbds_empty: 76

This means that the RX ring became empty (with no RX BDs) 76 times.
It doesn't necessarily mean packets were dropped yet because the chip
will continue to buffer using on-chip buffers.

>      rx_discards: 14

But this means that 14 packets were dropped because on-chip buffers
were full.  I don't know why it is not matching the 40000 missing
packets reported by the application.

>      mbuf_lwm_thresh_hit: 14

This means that the low on-chip buffer threshold was crossed 14 times.
This should trigger pause frames to be sent if flow control is
enabled.

> /sys/class/net/em2/statistics/multicast 763
> /sys/class/net/em2/statistics/rx_bytes 4589028558
> /sys/class/net/em2/statistics/rx_missed_errors 14
> /sys/class/net/em2/statistics/rx_packets 21433169
> /sys/class/net/em2/statistics/tx_bytes 4344
> /sys/class/net/em2/statistics/tx_packets 49
>

[-- Attachment #2: S/MIME Cryptographic Signature --]
[-- Type: application/pkcs7-signature, Size: 4209 bytes --]

      parent reply	other threads:[~2022-05-22 23:22 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-18 16:08 tg3 dropping packets at high packet rates David Laight
2022-05-18 17:27 ` Paolo Abeni
2022-05-18 21:31   ` David Laight
2022-05-19  0:52     ` Michael Chan
2022-05-19  8:44       ` David Laight
2022-05-19 10:20         ` Pavan Chebbi
2022-05-19 13:14           ` David Laight
2022-05-19 13:29             ` Paolo Abeni
2022-05-19 13:54               ` Andrew Lunn
2022-05-19 14:11               ` David Laight
2022-05-19 14:35                 ` Pavan Chebbi
2022-05-19 14:42                   ` David Laight
2022-05-20 16:08                     ` David Laight
2022-05-23 16:01                       ` David Laight
2022-05-23 16:14                         ` Pavan Chebbi
2022-05-23 21:23                           ` David Laight
2022-05-25  7:28                             ` David Laight
2022-05-25 15:56                               ` Jakub Kicinski
2022-05-25 21:48                                 ` David Laight
2022-05-22 23:22         ` Michael Chan [this message]

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=CACKFLinYSWgbKL-gtYgqLCkgC9CwqQoDK0tCG_-7Jy+3dfhuww@mail.gmail.com \
    --to=michael.chan@broadcom.com \
    --cc=David.Laight@aculab.com \
    --cc=davem@davemloft.net \
    --cc=mchan@broadcom.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=pavan.chebbi@broadcom.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).