Netdev List
 help / color / mirror / Atom feed
From: Paolo Abeni <pabeni@redhat.com>
To: Michael Chan <michael.chan@broadcom.com>, davem@davemloft.net
Cc: netdev@vger.kernel.org, edumazet@google.com, kuba@kernel.org,
	andrew+netdev@lunn.ch, pavan.chebbi@broadcom.com,
	andrew.gospodarek@broadcom.com
Subject: Re: [PATCH net-next v4 09/15] bnxt_en: Add infrastructure for crypto key context IDs
Date: Thu, 2 Jul 2026 09:53:54 +0200	[thread overview]
Message-ID: <3cce00d1-fdeb-4280-ab4c-077779bb82d6@redhat.com> (raw)
In-Reply-To: <20260629184921.3496727-10-michael.chan@broadcom.com>

On 6/29/26 8:49 PM, Michael Chan wrote:
> +/**
> + * bnxt_clear_crypto - Clear all crypto key contexts
> + * @bp: pointer to bnxt device
> + *
> + * Clears all key context allocations during shutdown or firmware reset.
> + * Frees all key info structures and bitmaps, and increments the epoch
> + * counter to invalidate any outstanding key references.
> + *
> + * This function assumes serialization (called during shutdown) and does
> + * not use locking.
> + *
> + * Context: Process context during shutdown/reset
> + */
> +void bnxt_clear_crypto(struct bnxt *bp)
> +{
> +	struct bnxt_crypto_info *crypto = bp->crypto_info;
> +	struct bnxt_kid_info *kid, *tmp;
> +	struct bnxt_kctx *kctx;
> +	int i;
> +
> +	if (!crypto)
> +		return;
> +
> +	/* Only called when shutting down or FW reset with BNXT_STATE_OPEN
> +	 * cleared, so no concurrent access.  No protection needed.
> +	 */
> +	for (i = 0; i < BNXT_MAX_CRYPTO_KEY_TYPE; i++) {
> +		kctx = &crypto->kctx[i];
> +		list_for_each_entry_safe(kid, tmp, &kctx->list, list) {
> +			list_del(&kid->list);
> +			kfree(kid);

Sashiko still complains about RCU rules violation here, and the complain
looks legit to me.

Note that to streamline patch processing you are expected to reply to
sashiko comments outline why they are (not) legit.

/P


  reply	other threads:[~2026-07-02  7:54 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-06-29 18:49 [PATCH net-next v4 00/15] bnxt_en: Add kTLS TX offload support Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 01/15] bnxt_en: Add Midpath channel information Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 02/15] bnxt_en: Account for the MPC TX and CP rings Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 03/15] bnxt_en: Set default MPC ring count Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 04/15] bnxt_en: Rename xdp_tx_lock to tx_lock Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 05/15] bnxt_en: Allocate and free MPC software structures Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 06/15] bnxt_en: Allocate and free MPC channels from firmware Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 07/15] bnxt_en: Allocate crypto structure and backing store Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 08/15] bnxt_en: Reserve crypto RX and TX key contexts on a PF Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 09/15] bnxt_en: Add infrastructure for crypto key context IDs Michael Chan
2026-07-02  7:53   ` Paolo Abeni [this message]
2026-06-29 18:49 ` [PATCH net-next v4 10/15] bnxt_en: Add MPC transmit and completion functions Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 11/15] bnxt_en: Add crypto MPC transmit/completion infrastructure Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 12/15] bnxt_en: Support kTLS TX offload by implementing .tls_dev_add/del() Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 13/15] bnxt_en: Implement kTLS TX normal path Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 14/15] bnxt_en: Add support for inline transmit BDs Michael Chan
2026-06-29 18:49 ` [PATCH net-next v4 15/15] bnxt_en: Add kTLS retransmission support Michael Chan
2026-07-02  7:55   ` Paolo Abeni

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=3cce00d1-fdeb-4280-ab4c-077779bb82d6@redhat.com \
    --to=pabeni@redhat.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=andrew.gospodarek@broadcom.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kuba@kernel.org \
    --cc=michael.chan@broadcom.com \
    --cc=netdev@vger.kernel.org \
    --cc=pavan.chebbi@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox