From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.2 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 584F3C48BE8 for ; Wed, 16 Jun 2021 12:02:42 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 33F556128C for ; Wed, 16 Jun 2021 12:02:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232421AbhFPMEr (ORCPT ); Wed, 16 Jun 2021 08:04:47 -0400 Received: from mail.kernel.org ([198.145.29.99]:43684 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231769AbhFPMEq (ORCPT ); Wed, 16 Jun 2021 08:04:46 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id A9E616115C; Wed, 16 Jun 2021 12:02:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1623844960; bh=r1XXnoZn4fycKBh7dG52yzkfQjPxg8rqCudLuUlkO0w=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ufQCIBYc6+C+4lcsK3ToW4W0KxXEOgfj1j/mhK0EfTNFGcxlGWUVIN7e0i8Mtc7Cb GTnIQ6t3sgIU0i7U9H6TCAy9NabUFLvUE4ngOc747BcQ0QN8SrfeFuUqIzXxEyctWH p+3Gl9OFC7ERRJBgE+Z8oiY4MobL8SLCa2o0r4iaV8gCL1SxZNfIJlwk3Up1a4MJYK nuzBEH/DgIKRDaREcsgWn1ObE5bgCiJ/aKawV03R0I15/ByS1VqzLIsDLUlPn6azNb dyfe4cyDlyIFbx0ADu13WO1yYUxqZ503tE/5h+oPR9+NgpDDudLx0LqBXIax2vyajl ZngcUXbuEZQmA== Date: Wed, 16 Jun 2021 17:32:36 +0530 From: Vinod Koul To: Mark Brown Cc: Bjorn Andersson , Wolfram Sang , linux-arm-msm@vger.kernel.org, Andy Gross , Matthias Kaehlcke , Douglas Anderson , Sumit Semwal , Amit Pundir , linux-spi@vger.kernel.org, linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 4/7] spi: spi-geni-qcom: Add support for GPI dma Message-ID: References: <20210111151651.1616813-1-vkoul@kernel.org> <20210111151651.1616813-5-vkoul@kernel.org> <20210111163504.GD4728@sirena.org.uk> <20210616113505.GB6418@sirena.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210616113505.GB6418@sirena.org.uk> Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org On 16-06-21, 12:35, Mark Brown wrote: > On Wed, Jun 16, 2021 at 02:20:45PM +0530, Vinod Koul wrote: > > > Looking at the code, that is ideal case. Only issue I can see is that > > core DMA mapping device being used is incorrect. The core would use > > ctlr->dev.parent which is the spi0 device here. > > Why would the parent of the controller be a SPI device? Sorry my bad, I meant the core use ctlr->dev.parent which in this case is the SPI master device, 880000.spi > > But in this case, that wont work. We have a parent qup device which is > > the parent for both spi and dma device and needs to be used for > > dma-mapping! > > > If we allow drivers to set dma mapping device and use that, then I can > > reuse the core. Let me know if that is agreeable to you and I can hack > > this up. Maybe add a new member in spi_controller which is filled by > > drivers in can_dma() callback? > > Possibly, I'd need to see the code. Ok, let me do a prototype and share ... Thanks -- ~Vinod