netdevsim: replace vfs_lock with devlink instance lock
authorJakub Kicinski <kuba@kernel.org>
Fri, 18 Mar 2022 19:23:43 +0000 (12:23 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 21 Mar 2022 14:11:38 +0000 (14:11 +0000)
commitaff3a925094633a5b77058b9a715efbb12fc2698
tree8b1f08cd68db53091d331c25bbe01a7a417d70c6
parent76eea6c2e663f7e9fbc258c82811ad9e657e085f
netdevsim: replace vfs_lock with devlink instance lock

Similarly to the previous commit, use the devlink instance
lock and let it replace the vfs_lock.

nsim_esw_legacy_enable() was locked by both port lock and
vfs lock so one set of lock/unlocks goes away.

netdevsim's .eswitch_mode_set callback is now ready for
the callback to take the instance lock.

Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/netdevsim/dev.c
drivers/net/netdevsim/netdevsim.h