From: Marc Kleine-Budde <mkl@pengutronix.de>
To: Vincent Mailhol <mailhol.vincent@wanadoo.fr>
Cc: Oliver Hartkopp <socketcan@hartkopp.net>, linux-can@vger.kernel.org
Subject: Re: [PATCH] can: dev: do not increment rx stats when generating a CAN error skb
Date: Fri, 19 Mar 2021 09:29:28 +0100 [thread overview]
Message-ID: <20210319082928.jaoxkrswpvdgnaae@pengutronix.de> (raw)
In-Reply-To: <20210317085223.91282-1-mailhol.vincent@wanadoo.fr>
[-- Attachment #1: Type: text/plain, Size: 812 bytes --]
On 17.03.2021 17:52:23, Vincent Mailhol wrote:
> CAN error skb is an interface specific to socket CAN. The CAN error
> skb does not correspond to any actual CAN frame sent on the wire. Only
> an error flag is transmitted when an error occurs (c.f. ISO 11898-1
> section 10.4.4.2 "Error flag").
>
> For this reason, it makes no sense to increment the rx_packets and
> rx_bytes fields of struct net_device_stats.
I think we increment the rx packets and bytes (more or less
consistently) in all drivers for CAN error skbs.
Marc
--
Pengutronix e.K. | Marc Kleine-Budde |
Embedded Linux | https://www.pengutronix.de |
Vertretung West/Dortmund | Phone: +49-231-2826-924 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2021-03-19 8:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-17 8:52 [PATCH] can: dev: do not increment rx stats when generating a CAN error skb Vincent Mailhol
2021-03-19 8:29 ` Marc Kleine-Budde [this message]
2021-03-19 9:41 ` Vincent MAILHOL
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=20210319082928.jaoxkrswpvdgnaae@pengutronix.de \
--to=mkl@pengutronix.de \
--cc=linux-can@vger.kernel.org \
--cc=mailhol.vincent@wanadoo.fr \
--cc=socketcan@hartkopp.net \
/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