Netdev List
 help / color / mirror / Atom feed
From: "Björn Töpel" <bjorn@kernel.org>
To: netdev-bot+sashiko@kernel.org, aleksander.lobakin@intel.com
Cc: magnus.karlsson@intel.com, maciej.fijalkowski@intel.com,
	ast@kernel.org, daniel@iogearbox.net, hawk@kernel.org,
	john.fastabend@gmail.com, andrii@kernel.org, eddyz87@gmail.com,
	memxor@gmail.com, davem@davemloft.net, edumazet@kernel.org,
	kuba@kernel.org, pabeni@redhat.com, willemb@google.com,
	netdev@vger.kernel.org, bpf@vger.kernel.org, horms@kernel.org,
	sdf@fomichev.me, martin.lau@linux.dev, song@kernel.org,
	yonghong.song@linux.dev, jolsa@kernel.org, emil@etsalapatis.com,
	ihor.solodrai@linux.dev, anthony.l.nguyen@intel.com,
	przemyslaw.kitszel@intel.com, intel-wired-lan@lists.osuosl.org,
	clecigne@google.com
Subject: Re: [PATCH net v2 1/4] libeth: xsk: Count each XDP_TX buffer on its own
Date: Tue, 01 Dec 2026 16:57:35 +0100	[thread overview]
Message-ID: <878q29ouxc.fsf@all.your.base.are.belong.to.us> (raw)
In-Reply-To: <179612875384.3146.6108168327530476978@kernel.org>

netdev-bot+sashiko@kernel.org writes:

> [Severity: High]
> Does the sign of this decrement match what idpf expects?

It doesn't, but that is older than this patch. libeth counts XDP_TX
completions down and idpf subtracts the result, so xdp_tx grows on both
send and completion, with or without this series. This patch only stops
libeth from reading the count from shared info that may change before
the bulk flush, and keeps the sign libeth already uses for XDP_TX and
XDP_XMIT.

Flipping the sign alone isn't safe either. For XDP_TX and XDP_XMIT the
completion subtracts all frags of a frame, while the send side adds only
the descriptors it posted, so the count has to become exact as well.

That is a separate fix. Olek, would you like to take it?


Björn

  reply	other threads:[~2026-12-01 15:57 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-30 12:37 [PATCH net v2 0/4] xsk: Keep the shared info of zero-copy buffers in kernel memory Björn Töpel
2026-11-30 12:37 ` [PATCH net v2 1/4] libeth: xsk: Count each XDP_TX buffer on its own Björn Töpel
2026-11-30 16:41   ` Alexander Lobakin
2026-12-01 12:39   ` netdev-bot+sashiko
2026-12-01 15:57     ` Björn Töpel [this message]
2026-11-30 12:37 ` [PATCH net v2 2/4] xdp: Size zero-copy skbs from the data, not the frame size Björn Töpel
2026-11-30 16:54   ` Alexander Lobakin
2026-12-01  7:12     ` Björn Töpel
2026-12-01 14:08       ` Alexander Lobakin
2026-12-01 12:39   ` netdev-bot+sashiko
2026-12-01 15:58     ` Björn Töpel
2026-11-30 12:37 ` [PATCH net v2 3/4] intel: Copy the exact length of XSk packets to skbs Björn Töpel
2026-11-30 16:56   ` Alexander Lobakin
2026-11-30 12:37 ` [PATCH net v2 4/4] xsk: Keep the shared info of zero-copy buffers in kernel memory Björn Töpel
2026-12-01 12:39   ` netdev-bot+sashiko
2026-12-01 16:01     ` Björn Töpel

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=878q29ouxc.fsf@all.your.base.are.belong.to.us \
    --to=bjorn@kernel.org \
    --cc=aleksander.lobakin@intel.com \
    --cc=andrii@kernel.org \
    --cc=anthony.l.nguyen@intel.com \
    --cc=ast@kernel.org \
    --cc=bpf@vger.kernel.org \
    --cc=clecigne@google.com \
    --cc=daniel@iogearbox.net \
    --cc=davem@davemloft.net \
    --cc=eddyz87@gmail.com \
    --cc=edumazet@kernel.org \
    --cc=emil@etsalapatis.com \
    --cc=hawk@kernel.org \
    --cc=horms@kernel.org \
    --cc=ihor.solodrai@linux.dev \
    --cc=intel-wired-lan@lists.osuosl.org \
    --cc=john.fastabend@gmail.com \
    --cc=jolsa@kernel.org \
    --cc=kuba@kernel.org \
    --cc=maciej.fijalkowski@intel.com \
    --cc=magnus.karlsson@intel.com \
    --cc=martin.lau@linux.dev \
    --cc=memxor@gmail.com \
    --cc=netdev-bot+sashiko@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=przemyslaw.kitszel@intel.com \
    --cc=sdf@fomichev.me \
    --cc=song@kernel.org \
    --cc=willemb@google.com \
    --cc=yonghong.song@linux.dev \
    /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