From patchwork Tue Sep 4 12:08:01 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Ujfalusi X-Patchwork-Id: 1416991 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id 9A59FDFFCF for ; Thu, 6 Sep 2012 16:26:27 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1T9eYj-0006FB-Rd; Thu, 06 Sep 2012 16:04:04 +0000 Received: from na3sys009aog138.obsmtp.com ([74.125.149.19]) by merlin.infradead.org with smtps (Exim 4.76 #1 (Red Hat Linux)) id 1T8rvE-0007Bk-HI for linux-arm-kernel@lists.infradead.org; Tue, 04 Sep 2012 12:08:01 +0000 Received: from mail-ob0-f177.google.com ([209.85.214.177]) (using TLSv1) by na3sys009aob138.postini.com ([74.125.148.12]) with SMTP ID DSNKUEXvH2lckyLYEJbW1CXBaABG4BwZQtOJ@postini.com; Tue, 04 Sep 2012 05:08:00 PDT Received: by obbta17 with SMTP id ta17so11264923obb.36 for ; Tue, 04 Sep 2012 05:07:58 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=TmQJliCmpV8LG85BEv/IiLOzZjow/4I5yQZ8dRYQBWc=; b=WhnuINfyFd+X3mU3zYLOa8HYaV2NKTXG4q01X4BW/oar9x0+olIlWlJ3ti0ApuH+si rGjM2+66QTuNR9V3HZmZAHP3KXIQKMvFXMCEs25ZOnXVBBblrnpI39JHDZQgEkrjYCeF L9e9HhIuvOOdRb+q2xgc+9e8SYk0XkIYlIVAfY3nsaWMTCDI4DJSb/z1D3noU1mSiORN yF0sKP0roHcfV7rh+olpJ4C1lTR5AG1mqgSneSCdVTFep8Mou3GY+orx8THQrfDGMjPD lCorEj7imrGY2s4kypsWQgwz6A8r7P/drX5oxFU31oaSTKxS5IU6NGJVDBXGxJvUzwQU eyTw== Received: by 10.60.25.193 with SMTP id e1mr15795866oeg.87.1346760478715; Tue, 04 Sep 2012 05:07:58 -0700 (PDT) Received: from barack.emea.dhcp.ti.com (dragon.ti.com. [192.94.94.33]) by mx.google.com with ESMTPS id g8sm14150577obz.16.2012.09.04.05.07.56 (version=SSLv3 cipher=OTHER); Tue, 04 Sep 2012 05:07:58 -0700 (PDT) From: Peter Ujfalusi To: Russell King , Janusz Krzysztofik Subject: [RFC update 1/2] dmaengine: omap: Support for element mode in cyclic DMA Date: Tue, 4 Sep 2012 15:08:01 +0300 Message-Id: <1346760482-12794-2-git-send-email-peter.ujfalusi@ti.com> X-Mailer: git-send-email 1.7.12 In-Reply-To: <1346760482-12794-1-git-send-email-peter.ujfalusi@ti.com> References: <1346760482-12794-1-git-send-email-peter.ujfalusi@ti.com> X-Gm-Message-State: ALoCoQnHtf4voM9bIcefavmXTNYhXmyXbKP4asgnYhgF5uMeCg2itlmphKERbMb4VNh1NAg8p4Fw X-Bad-Reply: References and In-Reply-To but no 'Re:' in Subject. X-Spam-Note: CRM114 invocation failed X-Spam-Score: -4.2 (----) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-4.2 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at http://www.dnswl.org/, medium trust [74.125.149.19 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Mailman-Approved-At: Thu, 06 Sep 2012 10:43:31 -0400 Cc: alsa-devel@alsa-project.org, Mark Brown , Santosh Shilimkar , Jarkko Nikula , linux-omap@vger.kernel.org, Liam Girdwood , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org When src_maxburst/dst_maxburst is set to 0 by the users of cyclic DMA (mostly audio) indicates that we should configure the omap DMA to element sync mode instead of packet mode. Signed-off-by: Peter Ujfalusi --- drivers/dma/omap-dma.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/dma/omap-dma.c b/drivers/dma/omap-dma.c index ae05618..b77a40d 100644 --- a/drivers/dma/omap-dma.c +++ b/drivers/dma/omap-dma.c @@ -413,7 +413,10 @@ static struct dma_async_tx_descriptor *omap_dma_prep_dma_cyclic( d->dev_addr = dev_addr; d->fi = burst; d->es = es; - d->sync_mode = OMAP_DMA_SYNC_PACKET; + if (burst) + d->sync_mode = OMAP_DMA_SYNC_PACKET; + else + d->sync_mode = OMAP_DMA_SYNC_ELEMENT; d->sync_type = sync_type; d->periph_port = OMAP_DMA_PORT_MPUI; d->sg[0].addr = buf_addr;