aboutsummaryrefslogtreecommitdiffstats
path: root/net/core/devlink.c
diff options
context:
space:
mode:
authorVlad Buslov <vladbu@nvidia.com>2022-08-29 14:13:24 +0200
committerJakub Kicinski <kuba@kernel.org>2022-08-30 23:21:17 -0700
commit21cb860c7f314be471d2dbcbfb659af405750500 (patch)
treee29f374b78a2960167eb0d27a934ae53a2355a04 /net/core/devlink.c
parentMerge branch 'mlxsw-configure-max-lag-id-for-spectrum-4' (diff)
downloadlinux-dev-21cb860c7f314be471d2dbcbfb659af405750500.tar.xz
linux-dev-21cb860c7f314be471d2dbcbfb659af405750500.zip
Revert "net: devlink: add RNLT lock assertion to devlink_compat_switch_id_get()"
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> Tested-by: Leon Romanovsky <leonro@nvidia.com> Link: https://lore.kernel.org/r/20220829121324.3980376-1-vladbu@nvidia.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/core/devlink.c')
-rw-r--r--net/core/devlink.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/net/core/devlink.c b/net/core/devlink.c
index 97a81b0a8ab4..7776dc82f88d 100644
--- a/net/core/devlink.c
+++ b/net/core/devlink.c
@@ -12437,8 +12437,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;