Commit 7ac1cc9a authored by Jakub Kicinski's avatar Jakub Kicinski Committed by David S. Miller

devlink: don't take instance lock around eswitch mode set

Changing switch mode may want to register and unregister devlink
ports.  Therefore similarly to DEVLINK_CMD_PORT_SPLIT/UNSPLIT it
should not take the instance lock.  Drivers don't depend on existing
locking since it's a very recent addition.
Signed-off-by: default avatarJakub Kicinski <jakub.kicinski@netronome.com>
Acked-by: default avatarJiri Pirko <jiri@mellanox.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 634c6b7a
...@@ -2756,7 +2756,8 @@ static const struct genl_ops devlink_nl_ops[] = { ...@@ -2756,7 +2756,8 @@ static const struct genl_ops devlink_nl_ops[] = {
.doit = devlink_nl_cmd_eswitch_set_doit, .doit = devlink_nl_cmd_eswitch_set_doit,
.policy = devlink_nl_policy, .policy = devlink_nl_policy,
.flags = GENL_ADMIN_PERM, .flags = GENL_ADMIN_PERM,
.internal_flags = DEVLINK_NL_FLAG_NEED_DEVLINK, .internal_flags = DEVLINK_NL_FLAG_NEED_DEVLINK |
DEVLINK_NL_FLAG_NO_LOCK,
}, },
{ {
.cmd = DEVLINK_CMD_DPIPE_TABLE_GET, .cmd = DEVLINK_CMD_DPIPE_TABLE_GET,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment