Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754513AbbLKJb5 (ORCPT ); Fri, 11 Dec 2015 04:31:57 -0500 Received: from mga09.intel.com ([134.134.136.24]:13194 "EHLO mga09.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752579AbbLKJbz (ORCPT ); Fri, 11 Dec 2015 04:31:55 -0500 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,412,1444719600"; d="scan'208";a="616335089" Date: Fri, 11 Dec 2015 15:05:02 +0530 From: Vinod Koul To: Sinan Kaya Cc: dmaengine@vger.kernel.org, timur@codeaurora.org, cov@codeaurora.org, jcm@redhat.com, agross@codeaurora.org, arnd@arndb.de, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH V7 3/3] dma: add Qualcomm Technologies HIDMA channel driver Message-ID: <20151211093502.GY1854@localhost> References: <1448245707-27499-1-git-send-email-okaya@codeaurora.org> <1448245707-27499-4-git-send-email-okaya@codeaurora.org> <20151130085948.GC3901@localhost> <565CAC4C.7080909@codeaurora.org> <20151201113458.GL3901@localhost> <565E0E1D.1040505@codeaurora.org> <565F40A5.2040701@codeaurora.org> <20151205080030.GJ1854@localhost> <5669DC48.2040402@codeaurora.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5669DC48.2040402@codeaurora.org> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1584 Lines: 41 On Thu, Dec 10, 2015 at 03:10:48PM -0500, Sinan Kaya wrote: > On 12/5/2015 3:00 AM, Vinod Koul wrote: > > On Wed, Dec 02, 2015 at 02:04:05PM -0500, Sinan Kaya wrote: > >>>>> You are missing the point. Channel can be paused, yes but the descriptor > >>>>> is in queue and is not paused. The descriptor running is paused, yes. > >>>>> There is subtle difference between these > >>> I'll follow your recommendation. PAUSE for the currently active > >>> descriptor and DMA_IN_PROGRESS for the rest. > >>> > >> > >> I'm now confused. > >> > >> I looked at several DMA driver implementations. > >> > >> 1. They call dma_cookie_status function to see if the job is done. > >> 2. If done, they return right ahead. > >> 3. Otherwise, dma_cookie_status returns DMA_IN_PROGRESS. > >> 4. Next the code checks if the channel is paused and return value is > >> DMA_IN_PROGRESS. The code changes return code to DMA_PAUSED. > >> > >> Whereas, I was returning paused first before even checking if the > >> descriptor is done. Are you OK with the sequence 1..4 above? > > > > Yes am okay with this with slight change in 4. > > > > You should set to PAUSED only for current descriptor and not for the ones in > > queue > > > > OK. I'll post a new version with this. Is there any other comment that > needed to be addressed? Looks okay to me -- ~Vinod -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/