]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx5: Fix potential deadlock in command mode change
authorMohamad Haj Yahia <mohamad@mellanox.com>
Thu, 30 Jun 2016 14:34:42 +0000 (17:34 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 Jul 2016 10:12:03 +0000 (06:12 -0400)
commit4a781d599d00ef9ea537998a59a655b60aa794e4
tree072607c40b60d2ba53cbb3c7dbf55617d38521dc
parentfd0395d4cf79a4bffb91a94fe069750115c80ebb
net/mlx5: Fix potential deadlock in command mode change

Call command completion handler in case of timeout when working in
interrupts mode.
Avoid flushing the commands workqueue after acquiring the semaphores to
prevent a potential deadlock.

Fixes: ffaf2c1a3989 ('mlx5: Add driver for Mellanox Connect-IB adapters')
Signed-off-by: Mohamad Haj Yahia <mohamad@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx5/core/cmd.c