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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 964A3CD6E74 for ; Thu, 5 Sep 2024 17:36:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:In-Reply-To: Content-Transfer-Encoding:Content-Type:MIME-Version:References:Message-ID: Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=eIgzal7ITyKn4Uu6UhwVaplHaAv3wUp9Qsoun/N+n+c=; b=lmviQL3LVUFd4UkPw4ITxfictr h6HvlG2e660nbu1ZeX45LOAPIf02UkRaAyJvs+OdtUIVtNS2K2YgEo09VDeJ/zlxV20XVw7KiZ1uU iQL0GUwDCrFj+8EI/UUnVPR8uGL5oYy+yeEPPoNax2nq6TmCxwodL/kC7ZcrOH8L9adKeaoamuNPm jcReQRTeG3819tw2FyzmkwhUXcHWGj3KDsB2XwUvoRX7gurgs7EYhbInnzXnjBFEQrLl7upmQLr0e XdblEoKJl4HIm6UqA6Z8oDWqvRVFjucuturQY+4DbSURiYQ91qYODx5wR4RbivdF5R+tvxwhkG/K6 73+bST/A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1smGOl-00000009JAT-1sSK; Thu, 05 Sep 2024 17:35:59 +0000 Received: from mail-pl1-x636.google.com ([2607:f8b0:4864:20::636]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1smGNm-00000009Ivg-1XGd for linux-arm-kernel@lists.infradead.org; Thu, 05 Sep 2024 17:34:59 +0000 Received: by mail-pl1-x636.google.com with SMTP id d9443c01a7336-20573eb852aso14943805ad.1 for ; Thu, 05 Sep 2024 10:34:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1725557697; x=1726162497; darn=lists.infradead.org; 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=eIgzal7ITyKn4Uu6UhwVaplHaAv3wUp9Qsoun/N+n+c=; b=CXm1bjSEDQy9YjTIa3z3Bga97sVOs1Mq0OSVeGjhzeclUeXmtYlHHYhtTmOH+xrt/r et8yycga6rexsrWQqDocWGptiL+gvx8DWXZB1k0PxLhrNSXgUyJePWfPgU8RZYRCnl81 qqCSGJohqlh8fwkNpnU/xlGOZBKAD426zv7FVygeSc5ERz1sAcDrVCpTpPffSPd+44tK a/hCMjThPpzYhNvJvhSE3GZ7lmHBb9UX62zd24UB4WitDcryvWejt2s/hvwZhKc62fGI //uS7Lt4FMLeNbbDOf1EFr43kW0yyNs7Xdq0MvDXXl/75f3ow3A7AT6yqrFxCAvncRm6 N8/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725557697; x=1726162497; 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=eIgzal7ITyKn4Uu6UhwVaplHaAv3wUp9Qsoun/N+n+c=; b=FEn83DuJVlGUSDE6uiCk7zGbw49rtijFx8VShFFhCdr64KdytqgscK9SFcMlMtPfca AYF5CZAKIyoStqlUOs+Oub3cro+rMSbFwjNvpQ3kvc4Dkq5p1e34ni0j6mrO1y9Oj4EP G/EYQ4JGfA72IzVGvLnE6gGn8IiMgE1s2b/gSL2meA/ErdzoxGUdxXwxpmt9UcJ1+9LZ UsKdHsBllSv4lVEkHGOwAstLRrFhxCoUvxQaFnjC0LY6N1JeFfNcI8l/9CLTv873EZRg GDTluKqOWi3Ql3IPrQYqTBElqCK/ozW3oHsy1lczO02iRQwY4KW/wQdqHC0Y9lyEbLfI sXJw== X-Forwarded-Encrypted: i=1; AJvYcCX4n54VrjZnpdiWOWKgpd/mmNa5U9nJjUgLoAT/KYYRAzR+Laor4XyYotmopqCtOxSq+PE5fkZc31Xk8OPN9stV@lists.infradead.org X-Gm-Message-State: AOJu0YxcmqL9ceLJ0L9hlzUzMkTbHUd6/n1bftNze2DjlzAu97alyTqv Xl9tW2kjsGIoM4wXPAAkL5gEFk8To8+H7PreibeCfE31dKioGYr2DYvIejc0uw== X-Google-Smtp-Source: AGHT+IElFJh9mBN0d10CvX+yxAjA8cHTDsSZBmgENNb/EtffZEORF9F48GUK1FqLfVaqnR4xQfoX8Q== X-Received: by 2002:a17:902:ea0a:b0:205:3475:63be with SMTP id d9443c01a7336-206eeb8c61amr497735ad.25.1725557696776; Thu, 05 Sep 2024 10:34:56 -0700 (PDT) Received: from thinkpad ([120.60.52.248]) by smtp.gmail.com with ESMTPSA id d9443c01a7336-206aea69770sm30809955ad.277.2024.09.05.10.34.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Sep 2024 10:34:56 -0700 (PDT) Date: Thu, 5 Sep 2024 23:04:37 +0530 From: Manivannan Sadhasivam To: Johan Hovold Cc: Richard Zhu , Lucas Stach , Lorenzo Pieralisi , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Rob Herring , Bjorn Helgaas , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , Jingoo Han , Chuanhua Lei , Marek Vasut , Yoshihiro Shimoda , linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, imx@lists.linux.dev, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, linux-arm-msm@vger.kernel.org, abel.vesa@linaro.org, johan+linaro@kernel.org, Shashank Babu Chinta Venkata Subject: Re: [PATCH v6 3/4] PCI: qcom: Add equalization settings for 16.0 GT/s Message-ID: <20240905173437.hm3hegv5zolaj7gj@thinkpad> References: <20240904-pci-qcom-gen4-stability-v6-0-ec39f7ae3f62@linaro.org> <20240904-pci-qcom-gen4-stability-v6-3-ec39f7ae3f62@linaro.org> <20240905152742.4llkcjvvu3klmo6j@thinkpad> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240905_103458_469812_8DD8C062 X-CRM114-Status: GOOD ( 25.14 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Sep 05, 2024 at 06:27:36PM +0200, Johan Hovold wrote: > On Thu, Sep 05, 2024 at 08:57:42PM +0530, Manivannan Sadhasivam wrote: > > On Wed, Sep 04, 2024 at 11:39:09AM +0200, Johan Hovold wrote: > > > > > diff --git a/drivers/pci/controller/dwc/pcie-qcom-common.h b/drivers/pci/controller/dwc/pcie-qcom-common.h > > > > new file mode 100644 > > > > index 000000000000..259e04b7bdf9 > > > > --- /dev/null > > > > +++ b/drivers/pci/controller/dwc/pcie-qcom-common.h > > > > @@ -0,0 +1,8 @@ > > > > +/* SPDX-License-Identifier: GPL-2.0 */ > > > > +/* > > > > + * Copyright (c) 2024 Qualcomm Innovation Center, Inc. All rights reserved. > > > > + */ > > > > + > > > > +#include "pcie-designware.h" > > > > > > You only need a forward declaration: > > > > > > struct dw_pcie; > > > > > > > + > > > > +void qcom_pcie_common_set_16gt_eq_settings(struct dw_pcie *pci); > > > > > > Compile guard still missing. > > Sorry, I meant to say *include* guard here. > Okay. I got confused initially. > > Perhaps we can just get rid of the Kconfig entry and build it by default for > > both RC and EP drivers? I don't see a value in building it as a separate module. > > And we may also move more common code in the future. > > It is already built by default for both drivers. I'm not sure what > you're suggesting here. > Right now it is selected by both drivers using a Kconfig symbol. But I'm thinking of building it by default as below: -obj-$(CONFIG_PCIE_QCOM) += pcie-qcom.o -obj-$(CONFIG_PCIE_QCOM_EP) += pcie-qcom-ep.o +obj-$(CONFIG_PCIE_QCOM) += pcie-qcom.o pcie-qcom-common.o +obj-$(CONFIG_PCIE_QCOM_EP) += pcie-qcom-ep.o pcie-qcom-common.o A separate Kconfig symbol is not really needed here as this file contains common code required by both the drivers. - Mani -- மணிவண்ணன் சதாசிவம்