Skip to content

Commit 2881093

Browse files
TE-N-ShengjiuWangvinodkoul
authored andcommitted
dmaengine: imx-sdma: Support 24bit/3bytes for sg mode
Update 3bytes buswidth that is supported by sdma. Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com> Signed-off-by: Vipul Kumar <vipul_kumar@mentor.com> Signed-off-by: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com> Acked-by: Robin Gong <yibin.gong@nxp.com> Reviewed-by: Joy Zou <joy.zou@nxp.com> Reviewed-by: Daniel Baluta <daniel.baluta@nxp.com> Signed-off-by: Frank Li <Frank.Li@nxp.com> Link: https://lore.kernel.org/r/20240329-sdma_upstream-v4-2-daeb3067dea7@nxp.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
1 parent 802ef22 commit 2881093

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

drivers/dma/imx-sdma.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@
176176

177177
#define SDMA_DMA_BUSWIDTHS (BIT(DMA_SLAVE_BUSWIDTH_1_BYTE) | \
178178
BIT(DMA_SLAVE_BUSWIDTH_2_BYTES) | \
179+
BIT(DMA_SLAVE_BUSWIDTH_3_BYTES) | \
179180
BIT(DMA_SLAVE_BUSWIDTH_4_BYTES))
180181

181182
#define SDMA_DMA_DIRECTIONS (BIT(DMA_DEV_TO_MEM) | \
@@ -1658,6 +1659,9 @@ static struct dma_async_tx_descriptor *sdma_prep_slave_sg(
16581659
if (count & 3 || sg->dma_address & 3)
16591660
goto err_bd_out;
16601661
break;
1662+
case DMA_SLAVE_BUSWIDTH_3_BYTES:
1663+
bd->mode.command = 3;
1664+
break;
16611665
case DMA_SLAVE_BUSWIDTH_2_BYTES:
16621666
bd->mode.command = 2;
16631667
if (count & 1 || sg->dma_address & 1)

0 commit comments

Comments
 (0)