From patchwork Fri Jan 20 17:58:24 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_R=C3=A9tornaz?= X-Patchwork-Id: 137064 Return-Path: X-Original-To: incoming-imx@patchwork.ozlabs.org Delivered-To: patchwork-incoming-imx@bilbo.ozlabs.org Received: from merlin.infradead.org (merlin.infradead.org [IPv6:2001:4978:20e::2]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id C02121007D1 for ; Sat, 21 Jan 2012 05:05:33 +1100 (EST) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1RoIo3-0003kG-Fi; Fri, 20 Jan 2012 18:03:19 +0000 Received: from smtp4.epfl.ch ([128.178.224.218]) by merlin.infradead.org with smtp (Exim 4.76 #1 (Red Hat Linux)) id 1RoInS-0003cY-Sg for linux-arm-kernel@lists.infradead.org; Fri, 20 Jan 2012 18:02:44 +0000 Received: (qmail 10462 invoked by uid 107); 20 Jan 2012 18:02:40 -0000 X-Virus-Scanned: ClamAV Received: from lsro1pc40.epfl.ch (HELO localhost.localdomain) (128.178.145.86) (authenticated) by smtp4.epfl.ch (AngelmatoPhylax SMTP proxy) with ESMTPA; Fri, 20 Jan 2012 19:02:40 +0100 From: =?utf-8?q?Philippe=20R=C3=A9tornaz?= To: s.hauer@pengutronix.de Subject: [PATCH 3/3] i.MX SDMA: Fix burstsize settings Date: Fri, 20 Jan 2012 18:58:24 +0100 Message-Id: <1327082304-11398-4-git-send-email-philippe.retornaz@epfl.ch> X-Mailer: git-send-email 1.6.3.3 In-Reply-To: <1327082304-11398-3-git-send-email-philippe.retornaz@epfl.ch> References: <1327082304-11398-1-git-send-email-philippe.retornaz@epfl.ch> <1327082304-11398-2-git-send-email-philippe.retornaz@epfl.ch> <1327082304-11398-3-git-send-email-philippe.retornaz@epfl.ch> MIME-Version: 1.0 X-Spam-Note: CRM114 invocation failed X-Spam-Score: -1.9 (-) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-1.9 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 T_RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: =?utf-8?q?Philippe=20R=C3=A9tornaz?= , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+incoming-imx=patchwork.ozlabs.org@lists.infradead.org List-Id: linux-imx-kernel.lists.patchwork.ozlabs.org Commit 6584cb88 fixed the mxcmmc driver but forgot to fix the SDMA driver to handle the correct burtsize. This make the SD card access works again with DMA on i.MX31 boards. Signed-off-by: Philippe Rétornaz Tested-by: Sascha Hauer Acked-by: Sascha Hauer --- drivers/dma/imx-sdma.c | 6 ++++-- 1 files changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/dma/imx-sdma.c b/drivers/dma/imx-sdma.c index f993955..c193dac 100644 --- a/drivers/dma/imx-sdma.c +++ b/drivers/dma/imx-sdma.c @@ -1095,11 +1095,13 @@ static int sdma_control(struct dma_chan *chan, enum dma_ctrl_cmd cmd, case DMA_SLAVE_CONFIG: if (dmaengine_cfg->direction == DMA_FROM_DEVICE) { sdmac->per_address = dmaengine_cfg->src_addr; - sdmac->watermark_level = dmaengine_cfg->src_maxburst; + sdmac->watermark_level = dmaengine_cfg->src_maxburst * + dmaengine_cfg->src_addr_width; sdmac->word_size = dmaengine_cfg->src_addr_width; } else { sdmac->per_address = dmaengine_cfg->dst_addr; - sdmac->watermark_level = dmaengine_cfg->dst_maxburst; + sdmac->watermark_level = dmaengine_cfg->dst_maxburst * + dmaengine_cfg->dst_addr_width; sdmac->word_size = dmaengine_cfg->dst_addr_width; } return sdma_config_channel(sdmac);