From: Andy Green Date: Mon, 29 Aug 2016 17:30:47 +0000 (-0700) Subject: k3dma: Fix hisi burst clipping X-Git-Tag: v4.9-rc1~102^2~8^2~7 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=6c28a90fb30cd3fe504e7dafe0b60b733f240f8c;p=karo-tx-linux.git k3dma: Fix hisi burst clipping Max burst len is a 4-bit field, but at the moment it's clipped with a 5-bit constant... reduce it to that which can be expressed Cc: Zhangfei Gao Cc: Krzysztof Kozlowski Cc: Maxime Ripard Cc: Vinod Koul Cc: Dan Williams Cc: Mark Brown Cc: Andy Green Acked-by: Zhangfei Gao Signed-off-by: Andy Green [jstultz: Forward ported to mainline] Signed-off-by: John Stultz Signed-off-by: Vinod Koul --- diff --git a/drivers/dma/k3dma.c b/drivers/dma/k3dma.c index 39de8980128c..3d514692bdc6 100644 --- a/drivers/dma/k3dma.c +++ b/drivers/dma/k3dma.c @@ -551,7 +551,7 @@ static int k3_dma_config(struct dma_chan *chan, c->ccfg |= (val << 12) | (val << 16); if ((maxburst == 0) || (maxburst > 16)) - val = 16; + val = 15; else val = maxburst - 1; c->ccfg |= (val << 20) | (val << 24);