All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: Michael Chan <michael.chan@broadcom.com>
Cc: davem@davemloft.net, netdev@vger.kernel.org, edumazet@google.com,
	pabeni@redhat.com, andrew+netdev@lunn.ch,
	pavan.chebbi@broadcom.com, andrew.gospodarek@broadcom.com,
	osk@google.com, Kalesh AP <kalesh-anakkur.purayil@broadcom.com>,
	Somnath Kotur <somnath.kotur@broadcom.com>
Subject: Re: [PATCH net 1/2] bnxt_en: Mask the bd_cnt field in the TX BD properly
Date: Mon, 24 Mar 2025 14:12:29 -0700	[thread overview]
Message-ID: <20250324141229.153b3adf@kernel.org> (raw)
In-Reply-To: <20250321211639.3812992-2-michael.chan@broadcom.com>

On Fri, 21 Mar 2025 14:16:38 -0700 Michael Chan wrote:
> The bd_cnt field in the TX BD specifies the total number of BDs for
> the TX packet.  The bd_cnt field has 5 bits and the maximum number
> supported is 32 with the value 0.
> 
> CONFIG_MAX_SKB_FRAGS can be modified and the total number of SKB
> fragments can approach or exceed the maximum supported by the chip.
> Add a macro to properly mask the bd_cnt field so that the value 32
> will be properly masked and set to 0 in the bd_cnd field.
> 
> Without this patch, the out-of-range bd_cnt value will corrupt the
> TX BD and may cause TX timeout.
> 
> The next patch will check for values exceeding 32.

Could you clarify how this patch improves things, exactly?
Patch 2/2 looks like the real fix, silently truncating 
the number of frags does not seem to make anything correct..
-- 
pw-bot: cr

  parent reply	other threads:[~2025-03-24 21:12 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-21 21:16 [PATCH net 0/2] bnxt_en: Fix MAX_SKB_FRAGS > 30 Michael Chan
2025-03-21 21:16 ` [PATCH net 1/2] bnxt_en: Mask the bd_cnt field in the TX BD properly Michael Chan
2025-03-24 16:50   ` Simon Horman
2025-03-24 21:12   ` Jakub Kicinski [this message]
2025-03-24 21:16     ` Michael Chan
2025-03-24 21:23       ` Jakub Kicinski
2025-03-21 21:16 ` [PATCH net 2/2] bnxt_en: Linearize TX SKB if the fragments exceed the max Michael Chan
2025-03-24 16:51   ` Simon Horman
2025-05-05 15:36   ` Eric Dumazet
2025-05-05 18:34     ` Michael Chan
2025-05-05 18:53       ` Eric Dumazet
2025-03-24 21:30 ` [PATCH net 0/2] bnxt_en: Fix MAX_SKB_FRAGS > 30 patchwork-bot+netdevbpf

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=20250324141229.153b3adf@kernel.org \
    --to=kuba@kernel.org \
    --cc=andrew+netdev@lunn.ch \
    --cc=andrew.gospodarek@broadcom.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kalesh-anakkur.purayil@broadcom.com \
    --cc=michael.chan@broadcom.com \
    --cc=netdev@vger.kernel.org \
    --cc=osk@google.com \
    --cc=pabeni@redhat.com \
    --cc=pavan.chebbi@broadcom.com \
    --cc=somnath.kotur@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 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.