From: Dan Carpenter <error27@gmail.com>
To: Orgad Shaneh <orgads@gmail.com>
Cc: gregkh@linuxfoundation.org, linux-staging@lists.linux.dev,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] staging: octeon: schedule the TX cleanup tasklet every 1024th packet
Date: Thu, 20 Aug 2026 21:48:13 +0300 [thread overview]
Message-ID: <aodL7aKfBYqNQig4@stanley.mountain> (raw)
In-Reply-To: <20260820113239.8169-1-orgads@gmail.com>
On Thu, Aug 20, 2026 at 02:32:39PM +0300, Orgad Shaneh wrote:
> cvm_oct_xmit() means to schedule the cleanup tasklet once every 1024
> packets, as its comment says, to cover the pathological case of heavy
> traffic on one port delaying the cleanup of another port blocked
> waiting for it.
>
> The test is inverted: total_to_clean & 0x3ff is true for 1023 of every
> 1024 values, and false only on the multiples of 1024. So the tasklet is
> scheduled on nearly every packet, and skipped on exactly the packet the
> comment wants. That costs one TASKLET softirq per transmitted packet,
> each walking every port and doing an FAU fetch-and-add per non-empty
> queue, and it buys nothing for this port, which already frees its
> completed skbs inline from the skb_to_free value it reads out of the
> FAU.
>
> Test the mask against zero. On a CN50XX board (2 cores at 300MHz)
> carrying ~6.9k transmitted packets/s, TASKLET softirqs drop from 7133/s
> to 597/s with no throughput change; the freeing work is conserved, so
> this removes softirq entries, not work.
>
> Fixes: 4898c560103f ("Staging: Octeon: Free transmit SKBs in a timely manner")
> Signed-off-by: Orgad Shaneh <orgads@gmail.com>
> ---
Reviewed-by: Dan Carpenter <error27@gmail.com>
regards,
dan carpenter
prev parent reply other threads:[~2026-08-20 18:48 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-20 11:32 [PATCH] staging: octeon: schedule the TX cleanup tasklet every 1024th packet Orgad Shaneh
2026-08-20 18:48 ` Dan Carpenter [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=aodL7aKfBYqNQig4@stanley.mountain \
--to=error27@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-staging@lists.linux.dev \
--cc=orgads@gmail.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