From: Srikanth Thokala <[email protected]>

This patch adds a sanity check to see if frame_size is 1.

Signed-off-by: Srikanth Thokala <[email protected]>
Signed-off-by: Michal Simek <[email protected]>
---
 drivers/dma/xilinx/xilinx_vdma.c | 3 +++
 1 file changed, 3 insertions(+)

Cc: [email protected]

diff --git a/drivers/dma/xilinx/xilinx_vdma.c b/drivers/dma/xilinx/xilinx_vdma.c
index 8e9f2a6..b3b8761 100644
--- a/drivers/dma/xilinx/xilinx_vdma.c
+++ b/drivers/dma/xilinx/xilinx_vdma.c
@@ -942,6 +942,9 @@ xilinx_vdma_dma_prep_interleaved(struct dma_chan *dchan,
        if (!xt->numf || !xt->sgl[0].size)
                return NULL;
 
+       if (xt->frame_size != 1)
+               return NULL;
+
        /* Allocate a transaction descriptor. */
        desc = xilinx_vdma_alloc_tx_descriptor(chan);
        if (!desc)
-- 
1.8.5.5

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to