Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp2830027rwl; Thu, 13 Apr 2023 11:24:27 -0700 (PDT) X-Google-Smtp-Source: AKy350av45W9d4QFky050iyAgK0VDkv+/yqcDZP6YF9GLZgsc+LRf/6mCwvJzbNYC37XRHQxLGkz X-Received: by 2002:a17:902:ce8c:b0:1a2:19c1:a96d with SMTP id f12-20020a170902ce8c00b001a219c1a96dmr3365507plg.23.1681410266883; Thu, 13 Apr 2023 11:24:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1681410266; cv=none; d=google.com; s=arc-20160816; b=wA7lp+vHLtLVp4LA+6wm5EyjrpYILgGI0NqgDCT0qks3HMbmPtkwaENMWH33qunIlT XEE2YN1EZIQWIVBy1C3yJlKyDPnuEOCLMGqGVe8I/lyxaOWjqwF/MNXYyM+UcaALtM/6 4Xykbtu8325oc1nyRgwFuqnUoyHUA4Fgg6CrlISpT3TrdnwdKLKM9RfYBpiZFE6/qkbD z8MYzDZT5UOuZ9azb7eYWCm6DS9KKK+Yxkv19QzaNIux4HMOWyAl23gZRRD9y+xnDfbQ I1bAycCixLSechGu4aDEQIoEP+058ubh+xtSZUp3CDKwEgl1X8x9hp/axrImduT1dq0b RLmA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=OZj7tX+onZ/w5nFTENrEQRRNbI5goS/EOTtR1AnrQuk=; b=koyaGqL1CkLaWW7lXRPEXNhczMizkJoPOl6vqwUFzgEtDCHWxZhS/tZeBWfPcSCgev nMLEMxyjoS6KnnwwaAe80veOmUuRVLv7CVsu7/ZXrdH64TsU6adZsaOSn2KDbbs79rMg idNTEle+E6bSren1jnC5CWBnYjf1uW4Q4B696k+bi8Pp45bD+csubS+SGe71bH6rkd4J PX0wPuDCsXLMA0jWAafyIjLxOPz4YASIQsvQAyzp+ibpglfrGRwgfv6kZC6ttayd29Cr n3Yvq9ltNBlvOdKKkFY3uQBBINlYi29pUmNMnVfO06k/CBcEbGFQa8VsZKGNF9/50KwK xA8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IvpeFWDP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h9-20020a170902680900b0019c3d2a71c6si2397766plk.489.2023.04.13.11.24.12; Thu, 13 Apr 2023 11:24:26 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=IvpeFWDP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229793AbjDMSXF (ORCPT + 99 others); Thu, 13 Apr 2023 14:23:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48754 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229580AbjDMSXE (ORCPT ); Thu, 13 Apr 2023 14:23:04 -0400 Received: from mail-pj1-x1029.google.com (mail-pj1-x1029.google.com [IPv6:2607:f8b0:4864:20::1029]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 688E04EF6 for ; Thu, 13 Apr 2023 11:23:02 -0700 (PDT) Received: by mail-pj1-x1029.google.com with SMTP id w11so16526436pjh.5 for ; Thu, 13 Apr 2023 11:23:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1681410182; x=1684002182; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date:from:to :cc:subject:date:message-id:reply-to; bh=OZj7tX+onZ/w5nFTENrEQRRNbI5goS/EOTtR1AnrQuk=; b=IvpeFWDPyAYXw5U9oh9b5vu7vcniXgjJddv7WuZKVPBhIU/UmNtY0Pcp0PAU6cHhlT W+F4P0pEgsiO9HO13LoBEThwGSODTeJaIcBlztIzFjcGG2dgeGd3wg1E8RmdYCqqjWGu 0bMTQNX8zsGvGSMtcEiJ7YVwHumxFQJsfSPwdJOOgTVbkQp6RvFoMUZSnBL/Af+q0mcm WWc58j/b0kHk3pwxzFpQUwopFHi2sYCvSyHpWeweHDCAzX7J5rQ2rHiAsUeFDfCgkUWY pPGnNcqAe56trAnIbfXY/cBcgl1ICBViGAHNvQFATNmeuJk76uv7UyLty9L7uwkiCjMD objw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1681410182; x=1684002182; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=OZj7tX+onZ/w5nFTENrEQRRNbI5goS/EOTtR1AnrQuk=; b=e5D5q6/Ep4joN/jScQuuig2wsCFU2+8rnDxnMAotEqBK+tCsUN3oCqfnzbxOj+L9le XzGeePExicrc6euZDfpogAudiK1+ilnMSIOGtdvHkKJACHaHO0XUCgLHztMAozuJwfHc GaMMgNr1G5ZBmdIS3905djHnYSA8VlLu3/WE6mlnvygXwSmew1b8rfnnqzOLCLtKYOJH R6NuAA0Md/yHKhqRRHbKy0+RnxmGIxwX3FaLKrhHp7zfi3gOHUyOksS/0J57p56HiBkj f7N4SPUXD6XRG60WIDxh/NwmNidY9DNb9A6xOKDc5FgnjQXT7aiuF4il/rGGdCHpswVk AB0w== X-Gm-Message-State: AAQBX9cCfcfQp3aC85YCTIrDE9cZeDNTs0kVsycN2SRqGESlWUC3qQuM vJdbo+C9VP6iTJWRAz571Ouu X-Received: by 2002:a17:903:22d0:b0:19e:b2ed:6fff with SMTP id y16-20020a17090322d000b0019eb2ed6fffmr3195821plg.31.1681410181764; Thu, 13 Apr 2023 11:23:01 -0700 (PDT) Received: from thinkpad ([59.97.52.67]) by smtp.gmail.com with ESMTPSA id 20-20020a170902ee5400b001a19bac463fsm1783106plo.42.2023.04.13.11.22.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 13 Apr 2023 11:23:01 -0700 (PDT) Date: Thu, 13 Apr 2023 23:52:54 +0530 From: Manivannan Sadhasivam To: Cai Huoqing Cc: fancer.lancer@gmail.com, Gustavo Pimentel , Vinod Koul , Jingoo Han , Lorenzo Pieralisi , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , linux-kernel@vger.kernel.org, dmaengine@vger.kernel.org, linux-pci@vger.kernel.org Subject: Re: [PATCH RESEND v9 1/4] dmaengine: dw-edma: Rename dw_edma_core_ops structure to dw_edma_plat_ops Message-ID: <20230413182254.GC13020@thinkpad> References: <20230413033156.93751-1-cai.huoqing@linux.dev> <20230413033156.93751-2-cai.huoqing@linux.dev> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20230413033156.93751-2-cai.huoqing@linux.dev> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 13, 2023 at 11:31:52AM +0800, Cai Huoqing wrote: > From: Cai huoqing > > The dw_edma_core_ops structure contains a set of the operations: > device IRQ numbers getter, CPU/PCI address translation. Based on the > functions semantics the structure name "dw_edma_plat_ops" looks more > descriptive since indeed the operations are platform-specific. The > "dw_edma_core_ops" name shall be used for a structure with the IP-core > specific set of callbacks in order to abstract out DW eDMA and DW HDMA > setups. Such structure will be added in one of the next commit in the > framework of the set of changes adding the DW HDMA device support. > > Anyway the renaming was necessary to distinguish two types of > the implementation callbacks: > 1. DW eDMA/hDMA IP-core specific operations: device-specific CSR > setups in one or another aspect of the DMA-engine initialization. > 2. DW eDMA/hDMA platform specific operations: the DMA device > environment configs like IRQs, address translation, etc. > > Signed-off-by: Cai huoqing > Reviewed-by: Serge Semin Reviewed-by: Manivannan Sadhasivam - Mani > --- > v8->v9: No change > > v8 link: > https://lore.kernel.org/lkml/20230323034944.78357-2-cai.huoqing@linux.dev/ > > drivers/dma/dw-edma/dw-edma-pcie.c | 4 ++-- > drivers/pci/controller/dwc/pcie-designware.c | 2 +- > include/linux/dma/edma.h | 4 ++-- > 3 files changed, 5 insertions(+), 5 deletions(-) > > diff --git a/drivers/dma/dw-edma/dw-edma-pcie.c b/drivers/dma/dw-edma/dw-edma-pcie.c > index 2b40f2b44f5e..1c6043751dc9 100644 > --- a/drivers/dma/dw-edma/dw-edma-pcie.c > +++ b/drivers/dma/dw-edma/dw-edma-pcie.c > @@ -109,7 +109,7 @@ static u64 dw_edma_pcie_address(struct device *dev, phys_addr_t cpu_addr) > return region.start; > } > > -static const struct dw_edma_core_ops dw_edma_pcie_core_ops = { > +static const struct dw_edma_plat_ops dw_edma_pcie_plat_ops = { > .irq_vector = dw_edma_pcie_irq_vector, > .pci_address = dw_edma_pcie_address, > }; > @@ -225,7 +225,7 @@ static int dw_edma_pcie_probe(struct pci_dev *pdev, > > chip->mf = vsec_data.mf; > chip->nr_irqs = nr_irqs; > - chip->ops = &dw_edma_pcie_core_ops; > + chip->ops = &dw_edma_pcie_plat_ops; > > chip->ll_wr_cnt = vsec_data.wr_ch_cnt; > chip->ll_rd_cnt = vsec_data.rd_ch_cnt; > diff --git a/drivers/pci/controller/dwc/pcie-designware.c b/drivers/pci/controller/dwc/pcie-designware.c > index 8e33e6e59e68..1f2ee71da4da 100644 > --- a/drivers/pci/controller/dwc/pcie-designware.c > +++ b/drivers/pci/controller/dwc/pcie-designware.c > @@ -828,7 +828,7 @@ static int dw_pcie_edma_irq_vector(struct device *dev, unsigned int nr) > return platform_get_irq_byname_optional(pdev, name); > } > > -static struct dw_edma_core_ops dw_pcie_edma_ops = { > +static struct dw_edma_plat_ops dw_pcie_edma_ops = { > .irq_vector = dw_pcie_edma_irq_vector, > }; > > diff --git a/include/linux/dma/edma.h b/include/linux/dma/edma.h > index d2638d9259dc..ed401c965a87 100644 > --- a/include/linux/dma/edma.h > +++ b/include/linux/dma/edma.h > @@ -40,7 +40,7 @@ struct dw_edma_region { > * iATU windows. That will be done by the controller > * automatically. > */ > -struct dw_edma_core_ops { > +struct dw_edma_plat_ops { > int (*irq_vector)(struct device *dev, unsigned int nr); > u64 (*pci_address)(struct device *dev, phys_addr_t cpu_addr); > }; > @@ -80,7 +80,7 @@ enum dw_edma_chip_flags { > struct dw_edma_chip { > struct device *dev; > int nr_irqs; > - const struct dw_edma_core_ops *ops; > + const struct dw_edma_plat_ops *ops; > u32 flags; > > void __iomem *reg_base; > -- > 2.34.1 > -- மணிவண்ணன் சதாசிவம்