All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jesper Dangaard Brouer <brouer@redhat.com>
To: Lorenzo Bianconi <lorenzo.bianconi@redhat.com>
Cc: Lorenzo Bianconi <lorenzo@kernel.org>,
	netdev@vger.kernel.org, ilias.apalodimas@linaro.org,
	davem@davemloft.net, David Ahern <dsahern@kernel.org>,
	BPF-dev-list <bpf@vger.kernel.org>,
	brouer@redhat.com
Subject: Re: [PATCH net-next 4/5] net: mvneta: introduce xdp counters to ethtool
Date: Mon, 17 Feb 2020 11:32:09 +0100	[thread overview]
Message-ID: <20200217113209.2dab7f71@carbon> (raw)
In-Reply-To: <20200217102550.GB3080@localhost.localdomain>

On Mon, 17 Feb 2020 11:25:50 +0100
Lorenzo Bianconi <lorenzo.bianconi@redhat.com> wrote:

> > On Sun, 16 Feb 2020 22:07:32 +0100
> > Lorenzo Bianconi <lorenzo@kernel.org> wrote:
> >   
> > > @@ -2033,6 +2050,7 @@ mvneta_xdp_submit_frame(struct mvneta_port *pp, struct mvneta_tx_queue *txq,
> > >  	u64_stats_update_begin(&stats->syncp);
> > >  	stats->es.ps.tx_bytes += xdpf->len;
> > >  	stats->es.ps.tx_packets++;
> > > +	stats->es.ps.xdp_tx++;
> > >  	u64_stats_update_end(&stats->syncp);  
> > 
> > I find it confusing that this ethtool stats is named "xdp_tx".
> > Because you use it as an "xmit" counter and not for the action XDP_TX.
> > 
> > Both XDP_TX and XDP_REDIRECT out this device will increment this
> > "xdp_tx" counter.  I don't think end-users will comprehend this...
> > 
> > What about naming it "xdp_xmit" ?  
> 
> Hi Jesper,
> 
> yes, I think it is definitely better. So to follow up:
> - rename current "xdp_tx" counter in "xdp_xmit" and increment it for
>   XDP_TX verdict and for ndo_xdp_xmit
> - introduce a new "xdp_tx" counter only for XDP_TX verdict.
> 
> If we agree I can post a follow-up patch.

I agree, that sounds like an improvement to this patchset.


I suspect David Ahern have some opinions about more general stats for
XDP, but that it is a more general discussion, that it outside this
patchset, but we should also have that discussion.

-- 
Best regards,
  Jesper Dangaard Brouer
  MSc.CS, Principal Kernel Engineer at Red Hat
  LinkedIn: http://www.linkedin.com/in/brouer


  reply	other threads:[~2020-02-17 10:32 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-16 21:07 [PATCH net-next 0/5] add xdp ethtool stats to mvneta driver Lorenzo Bianconi
2020-02-16 21:07 ` [PATCH net-next 1/5] net: mvneta: move refill_err and skb_alloc_err in per-cpu stats Lorenzo Bianconi
2020-02-16 21:07 ` [PATCH net-next 2/5] net: mvneta: rely on open-coding updating stats for non-xdp and tx path Lorenzo Bianconi
2020-02-16 21:07 ` [PATCH net-next 3/5] net: mvneta: rely on struct mvneta_stats in mvneta_update_stats routine Lorenzo Bianconi
2020-02-16 21:07 ` [PATCH net-next 4/5] net: mvneta: introduce xdp counters to ethtool Lorenzo Bianconi
2020-02-17 10:17   ` Jesper Dangaard Brouer
2020-02-17 10:25     ` Lorenzo Bianconi
2020-02-17 10:32       ` Jesper Dangaard Brouer [this message]
2020-02-17 13:05         ` Andrew Lunn
2020-02-17 14:51           ` Jesper Dangaard Brouer
2020-02-17 18:17             ` David Ahern
2020-02-17 22:18       ` David Miller
2020-02-17 22:38         ` Lorenzo Bianconi
2020-02-16 21:07 ` [PATCH net-next 5/5] net: mvneta: get rid of xdp_ret in mvneta_swbm_rx_frame Lorenzo Bianconi
2020-02-17  4:04 ` [PATCH net-next 0/5] add xdp ethtool stats to mvneta driver David Miller
2020-02-17  9:58   ` Jesper Dangaard Brouer
2020-02-17 22:10     ` David Miller

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=20200217113209.2dab7f71@carbon \
    --to=brouer@redhat.com \
    --cc=bpf@vger.kernel.org \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=ilias.apalodimas@linaro.org \
    --cc=lorenzo.bianconi@redhat.com \
    --cc=lorenzo@kernel.org \
    --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 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.