[v2,06/16] test/bbdev: report device status in test-bbdev

Message ID 20230215170949.60569-7-hernan.vargas@intel.com (mailing list archive)
State Superseded, archived
Delegated to: Maxime Coquelin
Headers
Series test/bbdev: changes for 23.03 |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Hernan Vargas Feb. 15, 2023, 5:09 p.m. UTC
  No functional impact.

Signed-off-by: Hernan Vargas <hernan.vargas@intel.com>
---
 app/test-bbdev/test_bbdev_perf.c | 2 ++
 1 file changed, 2 insertions(+)
  

Comments

Maxime Coquelin Feb. 20, 2023, 8:17 p.m. UTC | #1
On 2/15/23 18:09, Hernan Vargas wrote:
> No functional impact.
> 
> Signed-off-by: Hernan Vargas <hernan.vargas@intel.com>
> ---
>   app/test-bbdev/test_bbdev_perf.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/app/test-bbdev/test_bbdev_perf.c b/app/test-bbdev/test_bbdev_perf.c
> index 8c4b82efca..057fb5ac9e 100644
> --- a/app/test-bbdev/test_bbdev_perf.c
> +++ b/app/test-bbdev/test_bbdev_perf.c
> @@ -850,6 +850,8 @@ add_bbdev_dev(uint8_t dev_id, struct rte_bbdev_info *info,
>   #endif
>   	/* Let's refresh this now this is configured */
>   	rte_bbdev_info_get(dev_id, info);
> +	if (info->drv.device_status == RTE_BBDEV_DEV_FATAL_ERR)
> +		printf("Device Status %s\n", rte_bbdev_device_status_str(info->drv.device_status));
>   	nb_queues = RTE_MIN(rte_lcore_count(), info->drv.max_num_queues);
>   	nb_queues = RTE_MIN(nb_queues, (unsigned int) MAX_QUEUES);
>   

Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>

Thanks,
Maxime
  

Patch

diff --git a/app/test-bbdev/test_bbdev_perf.c b/app/test-bbdev/test_bbdev_perf.c
index 8c4b82efca..057fb5ac9e 100644
--- a/app/test-bbdev/test_bbdev_perf.c
+++ b/app/test-bbdev/test_bbdev_perf.c
@@ -850,6 +850,8 @@  add_bbdev_dev(uint8_t dev_id, struct rte_bbdev_info *info,
 #endif
 	/* Let's refresh this now this is configured */
 	rte_bbdev_info_get(dev_id, info);
+	if (info->drv.device_status == RTE_BBDEV_DEV_FATAL_ERR)
+		printf("Device Status %s\n", rte_bbdev_device_status_str(info->drv.device_status));
 	nb_queues = RTE_MIN(rte_lcore_count(), info->drv.max_num_queues);
 	nb_queues = RTE_MIN(nb_queues, (unsigned int) MAX_QUEUES);