From patchwork Thu Jul 14 12:42:37 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Ujfalusi X-Patchwork-Id: 9229757 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 3E0676075D for ; Thu, 14 Jul 2016 12:45:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2F6AC27FA9 for ; Thu, 14 Jul 2016 12:45:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 240E0281A7; Thu, 14 Jul 2016 12:45:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CCCAB27FA9 for ; Thu, 14 Jul 2016 12:45:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750960AbcGNMna (ORCPT ); Thu, 14 Jul 2016 08:43:30 -0400 Received: from bear.ext.ti.com ([198.47.19.11]:34672 "EHLO bear.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751133AbcGNMn2 (ORCPT ); Thu, 14 Jul 2016 08:43:28 -0400 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by bear.ext.ti.com (8.13.7/8.13.7) with ESMTP id u6ECgr5m015832; Thu, 14 Jul 2016 07:42:53 -0500 Received: from DFLE72.ent.ti.com (dfle72.ent.ti.com [128.247.5.109]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id u6ECgr7P019426; Thu, 14 Jul 2016 07:42:53 -0500 Received: from dflp33.itg.ti.com (10.64.6.16) by DFLE72.ent.ti.com (128.247.5.109) with Microsoft SMTP Server id 14.3.294.0; Thu, 14 Jul 2016 07:42:53 -0500 Received: from dlep33.itg.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id u6ECgjMV018322; Thu, 14 Jul 2016 07:42:51 -0500 From: Peter Ujfalusi To: CC: , , , , , Subject: [PATCH 2/7] dmaengine: omap-dma: Complete the cookie first on transfer completion Date: Thu, 14 Jul 2016 15:42:37 +0300 Message-ID: <20160714124242.7579-3-peter.ujfalusi@ti.com> X-Mailer: git-send-email 2.9.1 In-Reply-To: <20160714124242.7579-1-peter.ujfalusi@ti.com> References: <20160714124242.7579-1-peter.ujfalusi@ti.com> MIME-Version: 1.0 Sender: dmaengine-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: dmaengine@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Before looking for the next descriptor to start, complete the just finished cookie. Signed-off-by: Peter Ujfalusi --- drivers/dma/omap-dma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dma/omap-dma.c b/drivers/dma/omap-dma.c index 7d56cd88c9a5..f7b0b0c668fb 100644 --- a/drivers/dma/omap-dma.c +++ b/drivers/dma/omap-dma.c @@ -449,8 +449,8 @@ static void omap_dma_callback(int ch, u16 status, void *data) if (c->sgidx < d->sglen) { omap_dma_start_sg(c, d); } else { - omap_dma_start_desc(c); vchan_cookie_complete(&d->vd); + omap_dma_start_desc(c); } } else { vchan_cyclic_callback(&d->vd);