All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vlad Buslov <vladbu@nvidia.com>
To: <davem@davemloft.net>, <jiri@resnulli.us>, <kuba@kernel.org>
Cc: <netdev@vger.kernel.org>, <maord@nvidia.com>, <saeedm@nvidia.com>,
	<leon@kernel.org>, <roid@nvidia.com>, <jiri@nvidia.com>,
	Vlad Buslov <vladbu@nvidia.com>
Subject: [PATCH net-next] Revert "net: devlink: add RNLT lock assertion to devlink_compat_switch_id_get()"
Date: Mon, 29 Aug 2022 14:13:24 +0200	[thread overview]
Message-ID: <20220829121324.3980376-1-vladbu@nvidia.com> (raw)

This reverts commit 6005a8aecee8afeba826295321a612ab485c230e.

The assertion was intentionally removed in commit 043b8413e8c0 ("net:
devlink: remove redundant rtnl lock assert") and, contrary what is
described in the commit message, the comment reflects that: "Caller must
hold RTNL mutex or reference to dev...".

Signed-off-by: Vlad Buslov <vladbu@nvidia.com>
---
 net/core/devlink.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/net/core/devlink.c b/net/core/devlink.c
index 2afbeb6eca67..0f7078db1280 100644
--- a/net/core/devlink.c
+++ b/net/core/devlink.c
@@ -12505,8 +12505,6 @@ int devlink_compat_switch_id_get(struct net_device *dev,
 	 * devlink_port instance cannot disappear in the middle. No need to take
 	 * any devlink lock as only permanent values are accessed.
 	 */
-	ASSERT_RTNL();
-
 	devlink_port = netdev_to_devlink_port(dev);
 	if (!devlink_port || !devlink_port->switch_port)
 		return -EOPNOTSUPP;
-- 
2.36.1


             reply	other threads:[~2022-08-29 12:31 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-29 12:13 Vlad Buslov [this message]
2022-08-29 12:18 ` [PATCH net-next] Revert "net: devlink: add RNLT lock assertion to devlink_compat_switch_id_get()" Leon Romanovsky
2022-08-31  6: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=20220829121324.3980376-1-vladbu@nvidia.com \
    --to=vladbu@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=jiri@nvidia.com \
    --cc=jiri@resnulli.us \
    --cc=kuba@kernel.org \
    --cc=leon@kernel.org \
    --cc=maord@nvidia.com \
    --cc=netdev@vger.kernel.org \
    --cc=roid@nvidia.com \
    --cc=saeedm@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 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.