net/mlx5: Fix wait_vital for VFs and remove fixed sleep
authorDaniel Jurgens <danielj@mellanox.com>
Thu, 30 Jun 2016 14:34:41 +0000 (17:34 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 1 Jul 2016 10:12:03 +0000 (06:12 -0400)
commitd57847dc4177c6fd8d950cb533f5edf0eab45b11
treed6d9a413877cb51d19e2c5461dfb0bd67abc4f9e
parent5adff6a0886273eb426360400f120443833760a3
net/mlx5: Fix wait_vital for VFs and remove fixed sleep

The device ID for VFs is in a different location than PFs. This results
in the poll always timing out for VFs. There's no good way to read the
VF device ID without using the PF's configuration space.  Switch to waiting
for the health poll to start incrementing. Also remove the 1s sleep
at the beginning.

fixes: 89d44f0a6c73 ('net/mlx5_core: Add pci error handlers to mlx5_core
driver')
Signed-off-by: Daniel Jurgens <danielj@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/main.c