netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Saeed Mahameed <saeed@kernel.org>
To: Joel Fernandes <joel@joelfernandes.org>
Cc: Saeed Mahameed <saeedm@nvidia.com>,
	Leon Romanovsky <leon@kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Boris Pismenny <borisp@nvidia.com>,
	"Uladzislau Rezki (Sony)" <urezki@gmail.com>,
	Ariel Levkovich <lariel@nvidia.com>,
	Vlad Buslov <vladbu@nvidia.com>,
	"Paul E . McKenney" <paulmck@kernel.org>,
	netdev@vger.kernel.org, linux-rdma@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 06/14] net/mlx5: Rename kfree_rcu() to kfree_rcu_mightsleep()
Date: Mon, 27 Mar 2023 08:09:07 -0700	[thread overview]
Message-ID: <ZCGxk5k2yRGg3o33@x130> (raw)
In-Reply-To: <CAEXW_YQLQqB9CAzEyddzOJkKx3y268T7g-E313mDsjXVQRT0Dw@mail.gmail.com>

On 26 Mar 08:34, Joel Fernandes wrote:
>On Wed, Mar 15, 2023 at 2:19 PM Joel Fernandes (Google)
><joel@joelfernandes.org> wrote:
>>
>> From: "Uladzislau Rezki (Sony)" <urezki@gmail.com>
>>
>> The kfree_rcu() and kvfree_rcu() macros' single-argument forms are
>> deprecated.  Therefore switch to the new kfree_rcu_mightsleep() and
>> kvfree_rcu_mightsleep() variants. The goal is to avoid accidental use
>> of the single-argument forms, which can introduce functionality bugs in
>> atomic contexts and latency bugs in non-atomic contexts.
>
>In a world where patches anxiously await their precious Ack, could
>today be our lucky day on this one?
>
>We need Acks to take this in for 6.4. David? Others?
>

For mlx5 usually me, but since this is a larger series that is not mlx5
centric and targeting multiple tree, I really don't know which subsystem
you should be targeting.. for netdev submissions you need to specify the
targeted branch e.g. [PATCH v2 net-next 06/14] ... 


FWIW:

Reviewed-by: Saeed Mahameed <saeedm@nvidia.com>


> - Joel
>
>
>>
>> Cc: Ariel Levkovich <lariel@nvidia.com>
>> Cc: Saeed Mahameed <saeedm@nvidia.com>
>> Cc: Vlad Buslov <vladbu@nvidia.com>
>> Signed-off-by: Uladzislau Rezki (Sony) <urezki@gmail.com>
>> Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
>> Signed-off-by: Joel Fernandes (Google) <joel@joelfernandes.org>
>> ---
>>  drivers/net/ethernet/mellanox/mlx5/core/en/tc/int_port.c  | 2 +-
>>  drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c | 4 ++--
>>  2 files changed, 3 insertions(+), 3 deletions(-)
>>
>> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en/tc/int_port.c b/drivers/net/ethernet/mellanox/mlx5/core/en/tc/int_port.c
>> index ca834bbcb44f..8afcec0c5d3c 100644
>> --- a/drivers/net/ethernet/mellanox/mlx5/core/en/tc/int_port.c
>> +++ b/drivers/net/ethernet/mellanox/mlx5/core/en/tc/int_port.c
>> @@ -242,7 +242,7 @@ mlx5e_int_port_remove(struct mlx5e_tc_int_port_priv *priv,
>>                 mlx5_del_flow_rules(int_port->rx_rule);
>>         mapping_remove(ctx, int_port->mapping);
>>         mlx5e_int_port_metadata_free(priv, int_port->match_metadata);
>> -       kfree_rcu(int_port);
>> +       kfree_rcu_mightsleep(int_port);
>>         priv->num_ports--;
>>  }
>>
>> diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c
>> index 08d0929e8260..b811dad7370a 100644
>> --- a/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c
>> +++ b/drivers/net/ethernet/mellanox/mlx5/core/en_accel/macsec.c
>> @@ -670,7 +670,7 @@ static int mlx5e_macsec_del_txsa(struct macsec_context *ctx)
>>
>>         mlx5e_macsec_cleanup_sa(macsec, tx_sa, true);
>>         mlx5_destroy_encryption_key(macsec->mdev, tx_sa->enc_key_id);
>> -       kfree_rcu(tx_sa);
>> +       kfree_rcu_mightsleep(tx_sa);
>>         macsec_device->tx_sa[assoc_num] = NULL;
>>
>>  out:
>> @@ -849,7 +849,7 @@ static void macsec_del_rxsc_ctx(struct mlx5e_macsec *macsec, struct mlx5e_macsec
>>         xa_erase(&macsec->sc_xarray, rx_sc->sc_xarray_element->fs_id);
>>         metadata_dst_free(rx_sc->md_dst);
>>         kfree(rx_sc->sc_xarray_element);
>> -       kfree_rcu(rx_sc);
>> +       kfree_rcu_mightsleep(rx_sc);
>>  }
>>
>>  static int mlx5e_macsec_del_rxsc(struct macsec_context *ctx)
>> --
>> 2.40.0.rc1.284.g88254d51c5-goog
>>

  reply	other threads:[~2023-03-27 15:09 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20230315181902.4177819-1-joel@joelfernandes.org>
2023-03-15 18:18 ` [PATCH v2 05/14] net/sysctl: Rename kvfree_rcu() to kvfree_rcu_mightsleep() Joel Fernandes (Google)
2023-03-26 12:28   ` Joel Fernandes
2023-03-27 17:14     ` Jakub Kicinski
2023-03-15 18:18 ` [PATCH v2 06/14] net/mlx5: Rename kfree_rcu() to kfree_rcu_mightsleep() Joel Fernandes (Google)
2023-03-26 12:34   ` Joel Fernandes
2023-03-27 15:09     ` Saeed Mahameed [this message]
2023-03-15 18:18 ` [PATCH v2 12/14] mac802154: Rename kfree_rcu() to kvfree_rcu_mightsleep() Joel Fernandes (Google)
2023-03-16 16:41   ` Stefan Schmidt
2023-03-16 18:06     ` Joel Fernandes

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=ZCGxk5k2yRGg3o33@x130 \
    --to=saeed@kernel.org \
    --cc=borisp@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=joel@joelfernandes.org \
    --cc=kuba@kernel.org \
    --cc=lariel@nvidia.com \
    --cc=leon@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=paulmck@kernel.org \
    --cc=saeedm@nvidia.com \
    --cc=urezki@gmail.com \
    --cc=vladbu@nvidia.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;
as well as URLs for NNTP newsgroup(s).