mlxsw: pci: Wait after reset before accessing HW
authorYuval Mintz <yuvalm@mellanox.com>
Wed, 10 Jan 2018 10:42:43 +0000 (11:42 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 3 Mar 2018 09:24:38 +0000 (10:24 +0100)
commit819cbaae314ed04f7bd530f0e34c96b9612940eb
treeaa9fb28dcdd47f1b8a6dbe25296ab8595b9533d6
parent3d23aaff9e55227d9e786d3aee157c9df63f2efe
mlxsw: pci: Wait after reset before accessing HW

[ Upstream commit 8e033a93b37f37aa9fca71a370a895155320af60 ]

After performing reset driver polls on HW indication until learning
that the reset is done, but immediately after reset the device becomes
unresponsive which might lead to completion timeout on the first read.

Wait for 100ms before starting the polling.

Fixes: 233fa44bd67a ("mlxsw: pci: Implement reset done check")
Signed-off-by: Yuval Mintz <yuvalm@mellanox.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/ethernet/mellanox/mlxsw/pci.c
drivers/net/ethernet/mellanox/mlxsw/pci_hw.h