vdpa/mlx5: handle hardware error
authorXueming Li <xuemingl@nvidia.com>
Tue, 27 Oct 2020 08:28:45 +0000 (08:28 +0000)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 3 Nov 2020 22:35:05 +0000 (23:35 +0100)
commit0474419bae7c70117010e77c5278965fff9cbf9b
treee8486617b91833c20a306c2e3d010dd0c6bb9104
parentaed98b664c9720568344b0cb2fd0cd28b4fc7eb5
vdpa/mlx5: handle hardware error

When hardware error happens, vdpa didn't get such information and leave
driver in silent: working state but no response.

This patch subscribes firmware virtq error event and try to recover max
3 times in 3 seconds, stop virtq if max retry number reached.

When error happens, PMD log in warning level. If failed to recover,
outputs error log. Query virtq statistics to get error counters report.

Acked-by: Matan Azrad <matan@nvidia.com>
Signed-off-by: Xueming Li <xuemingl@nvidia.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>
doc/guides/rel_notes/release_20_11.rst
doc/guides/vdpadevs/mlx5.rst
drivers/vdpa/mlx5/mlx5_vdpa.c
drivers/vdpa/mlx5/mlx5_vdpa.h
drivers/vdpa/mlx5/mlx5_vdpa_event.c
drivers/vdpa/mlx5/mlx5_vdpa_virtq.c