OSDN Git Service

mlxsw: core_env: Convert 'module_info_lock' to a mutex
authorIdo Schimmel <idosch@nvidia.com>
Wed, 15 Sep 2021 10:13:08 +0000 (13:13 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 15 Sep 2021 15:17:15 +0000 (16:17 +0100)
commitbd6e43f5953d39d5cb06041d5ae3e9e5470336ef
treedbc6d8925c0c2d214677634857f94dc4e9c69154
parent163f3d2dd01cf9b8f58b56fe94ce517e468385a9
mlxsw: core_env: Convert 'module_info_lock' to a mutex

After the previous patch, the lock is always taken in process context so
it can be converted to a mutex. It is needed for future changes where we
will need to be able to sleep when holding the lock.

Convert the lock to a mutex.

Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlxsw/core_env.c