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.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=unavailable 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 9695AC433E0 for ; Fri, 15 May 2020 15:08:22 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7E6D02076A for ; Fri, 15 May 2020 15:08:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726727AbgEOPIW (ORCPT ); Fri, 15 May 2020 11:08:22 -0400 Received: from mga06.intel.com ([134.134.136.31]:30332 "EHLO mga06.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726248AbgEOPIV (ORCPT ); Fri, 15 May 2020 11:08:21 -0400 IronPort-SDR: 03KPQs3+8c13VIvq/NtdVP3rq732cgCH+NnjvI2mK9bJmLaSymBZUcKI9/8Y/TuzLIlfhVz58g wuiCCLosyTRA== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 15 May 2020 08:08:21 -0700 IronPort-SDR: KN+Wg87nK8SnMqebrA5QJEz/3xsD/rYTEyQsxaeuNjYdmePiwQbiGrKQN3c/S0v5063fyk0q1N z8hCmYZjdaSg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,395,1583222400"; d="scan'208";a="253813911" Received: from smile.fi.intel.com (HELO smile) ([10.237.68.40]) by fmsmga008.fm.intel.com with ESMTP; 15 May 2020 08:08:16 -0700 Received: from andy by smile with local (Exim 4.93) (envelope-from ) id 1jZbwg-006tV6-Bb; Fri, 15 May 2020 18:08:18 +0300 Date: Fri, 15 May 2020 18:08:18 +0300 From: Andy Shevchenko To: Serge Semin Cc: Mark Brown , Serge Semin , Georgy Vlasov , Ramil Zaripov , Alexey Malahov , Thomas Bogendoerfer , Paul Burton , Ralf Baechle , Arnd Bergmann , Allison Randal , Gareth Williams , Rob Herring , linux-mips@vger.kernel.org, devicetree@vger.kernel.org, Wan Ahmad Zainie , Jarkko Nikula , Jay Fang , Thomas Gleixner , YueHaibing , Stephen Boyd , linux-spi@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 17/19] spi: dw: Add DMA support to the DW SPI MMIO driver Message-ID: <20200515150818.GP1634618@smile.fi.intel.com> References: <20200508132943.9826-1-Sergey.Semin@baikalelectronics.ru> <20200515104758.6934-1-Sergey.Semin@baikalelectronics.ru> <20200515104758.6934-18-Sergey.Semin@baikalelectronics.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200515104758.6934-18-Sergey.Semin@baikalelectronics.ru> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, May 15, 2020 at 01:47:56PM +0300, Serge Semin wrote: > Since the common code in the spi-dw-dma.c driver is ready to be used > by the MMIO driver and now provides a method to generically (on any > DT or ACPI-based platforms) retrieve the Tx/Rx DMA channel handlers, > we can use it and a set of the common DW SPI DMA callbacks to enable > DMA at least for generic "snps,dw-apb-ssi" and "snps,dwc-ssi-1.01a" > devices. Reviewed-by: Andy Shevchenko > > Co-developed-by: Georgy Vlasov > Signed-off-by: Georgy Vlasov > Co-developed-by: Ramil Zaripov > Signed-off-by: Ramil Zaripov > Signed-off-by: Serge Semin > Cc: Alexey Malahov > Cc: Thomas Bogendoerfer > Cc: Paul Burton > Cc: Ralf Baechle > Cc: Arnd Bergmann > Cc: Allison Randal > Cc: Andy Shevchenko > Cc: Gareth Williams > Cc: Rob Herring > Cc: linux-mips@vger.kernel.org > Cc: devicetree@vger.kernel.org > --- > drivers/spi/spi-dw-mmio.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/drivers/spi/spi-dw-mmio.c b/drivers/spi/spi-dw-mmio.c > index 0894b4c09496..e23d0c53a664 100644 > --- a/drivers/spi/spi-dw-mmio.c > +++ b/drivers/spi/spi-dw-mmio.c > @@ -149,6 +149,8 @@ static int dw_spi_dw_apb_init(struct platform_device *pdev, > /* Register hook to configure CTRLR0 */ > dwsmmio->dws.update_cr0 = dw_spi_update_cr0; > > + dw_spi_dma_setup_generic(&dwsmmio->dws); > + > return 0; > } > > @@ -158,6 +160,8 @@ static int dw_spi_dwc_ssi_init(struct platform_device *pdev, > /* Register hook to configure CTRLR0 */ > dwsmmio->dws.update_cr0 = dw_spi_update_cr0_v1_01a; > > + dw_spi_dma_setup_generic(&dwsmmio->dws); > + > return 0; > } > > -- > 2.25.1 > -- With Best Regards, Andy Shevchenko