This patch add support to use multiple dma channel in the driver.

Signed-off-by: Gagandeep Singh <g.si...@nxp.com>
---
 drivers/dma/dpaa/dpaa_qdma.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/dma/dpaa/dpaa_qdma.c b/drivers/dma/dpaa/dpaa_qdma.c
index 10e65ef1d7..24ad7ad019 100644
--- a/drivers/dma/dpaa/dpaa_qdma.c
+++ b/drivers/dma/dpaa/dpaa_qdma.c
@@ -1,5 +1,5 @@
 /* SPDX-License-Identifier: BSD-3-Clause
- * Copyright 2021 NXP
+ * Copyright 2021-2024 NXP
  */
 
 #include <bus_dpaa_driver.h>
@@ -648,8 +648,8 @@ fsl_qdma_alloc_chan_resources(struct fsl_qdma_chan 
*fsl_chan)
        }
 
 finally:
-       return fsl_qdma->desc_allocated++;
-
+       fsl_qdma->desc_allocated++;
+       return 0;
 exit:
        return -ENOMEM;
 }
@@ -670,7 +670,7 @@ dpaa_info_get(const struct rte_dma_dev *dev, struct 
rte_dma_info *dev_info,
                             RTE_DMA_CAPA_DEV_TO_MEM |
                             RTE_DMA_CAPA_SILENT |
                             RTE_DMA_CAPA_OPS_COPY;
-       dev_info->max_vchans = 1;
+       dev_info->max_vchans = 4;
        dev_info->max_desc = DPAADMA_MAX_DESC;
        dev_info->min_desc = DPAADMA_MIN_DESC;
 
-- 
2.25.1

Reply via email to