linux/drivers/net/netdevsim
Jiri Pirko 075935f0ae devlink: protect devlink param list by instance lock
Commit 1d18bb1a4d ("devlink: allow registering parameters after
the instance") as the subject implies introduced possibility to register
devlink params even for already registered devlink instance. This is a
bit problematic, as the consistency or params list was originally
secured by the fact it is static during devlink lifetime. So in order to
protect the params list, take devlink instance lock during the params
operations. Introduce unlocked function variants and use them in drivers
in locked context. Put lock assertions to appropriate places.

Signed-off-by: Jiri Pirko <jiri@nvidia.com>
Reviewed-by: Jakub Kicinski <kuba@kernel.org>
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Simon Horman <simon.horman@corigine.com>
Tested-by: Simon Horman <simon.horman@corigine.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2023-01-27 12:32:02 +00:00
..
bpf.c netdevsim: Avoid allocation warnings triggered from user space 2022-07-29 14:57:26 -07:00
bus.c netdevsim: fix memory leak in nsim_bus_dev_new() 2022-10-27 10:47:09 -07:00
dev.c devlink: protect devlink param list by instance lock 2023-01-27 12:32:02 +00:00
ethtool.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2021-12-16 16:13:19 -08:00
fib.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2022-08-03 09:04:55 +02:00
health.c devlink: protect health reporter operation with instance lock 2023-01-19 19:08:37 -08:00
hwstats.c netdevsim: Fix hwstats debugfs file permissions 2022-09-19 14:40:38 -07:00
ipsec.c netdevsim: Fill IPsec state validation failure reason 2023-01-26 16:28:48 -08:00
Makefile netdevsim: Introduce support for L3 offload xstats 2022-03-15 14:00:51 +01:00
netdev.c net: remove unused ndo_get_devlink_port 2022-11-03 20:48:36 -07:00
netdevsim.h netdevsim: convert driver to use unlocked devlink API during init/fini 2022-07-18 20:10:48 -07:00
psample.c netdevsim: Only use sampling truncation length when valid 2021-04-22 13:23:56 -07:00
udp_tunnels.c netdevsim: set .owner to THIS_MODULE 2020-11-17 14:08:59 -08:00