From 0623f2758baa4bf1c347439ecf1ca03543b7b381 Mon Sep 17 00:00:00 2001 From: Kevin Laatz Date: Mon, 11 Mar 2024 15:25:50 +0000 Subject: [PATCH] test/dma: fix stats tear down The API testsuite previously only used the dmadev skeleton. Now that real devices are being used for the API tests, the DMA stats need to be reset during testsuite teardown to ensure a known, clean state before continuing. Fixes: 14b477ed1740 ("test/dma: use unit test framework") Signed-off-by: Kevin Laatz Acked-by: Chengwen Feng --- app/test/test_dmadev_api.c | 1 + 1 file changed, 1 insertion(+) diff --git a/app/test/test_dmadev_api.c b/app/test/test_dmadev_api.c index a130e74b51a..d40c05cfbfa 100644 --- a/app/test/test_dmadev_api.c +++ b/app/test/test_dmadev_api.c @@ -82,6 +82,7 @@ testsuite_teardown(void) dst = NULL; /* Ensure the dmadev is stopped. */ rte_dma_stop(test_dev_id); + rte_dma_stats_reset(test_dev_id, RTE_DMA_ALL_VCHAN); rte_log_set_level_pattern("lib.dmadev", RTE_LOG_INFO); }