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 87B43D2CE05 for ; Tue, 22 Oct 2024 17:03:04 +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=pPeTnArfy3kVD9qdVEi17t1QYmpfbQ/+MP9HcRzS7Mw=; b=B1BOX4TrCFvBFBRdIa5QbyCvaq /LVSdSAracKDBZU1DEkFIwfLIuDlsfvUjs783o1F26FmDukXmOR7SbNiEREjWTVvQTQu+5Azqdz8/ W6NG/RR23MFRk9DxrIHYHWGZ7qZRh2qLCadifxHzRw7YmkeUsJLfA+Q4YlpSi7Qi/hTynZaX+RWKN wNsxVtpgD48FQw3uxuZ7czeFK/LiZcF2eOn1cdwRgZHMskbyUXtIxFleQG6lGyo+gUZf5XSwYpfKm 1iN+kS0b9F1yxPD2dYIGPo5tAu6pBdqe4GgL5qpPFdQtO2XwTsx6gJ7WyNHoD2F3RPQr8YctNlsjm YAf4Gsgw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t3IHS-0000000BaLw-3BiX; Tue, 22 Oct 2024 17:02:50 +0000 Received: from mail-pf1-x42d.google.com ([2607:f8b0:4864:20::42d]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t3I1L-0000000BWbM-1W6u for linux-arm-kernel@lists.infradead.org; Tue, 22 Oct 2024 16:46:12 +0000 Received: by mail-pf1-x42d.google.com with SMTP id d2e1a72fcca58-71ec1216156so2249293b3a.2 for ; Tue, 22 Oct 2024 09:46:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1729615570; x=1730220370; 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=pPeTnArfy3kVD9qdVEi17t1QYmpfbQ/+MP9HcRzS7Mw=; b=V6bjL5/vZSd1RHPCSCaYfnXtq4pv9sF1LvzFN2/HuI5L4oN6UzNBfqXNwHCzdBlP+7 8cR1McwSdCdZWya979Bs7j1cQmtza24cij9P+0R3yqQns3Avu5jyo5bUuOixEqFAxXDX VqX15t5oTAn4V2ci8GowN2sGnQGZSmMbTEQnXO8+UZUSljFlyTQhefCAb9eK7FxuHyu3 CMPzIBbZclPXQoypoUeWGx1OC/w4dZXvSck9GGa6fnnn65h4/QfURizoCsFxvxh7UxH8 gmZlRfAe9O/cif6AyIk3hZF3WKnT84vl5awTu7qMKFVPzeu2Y7JcIWjxcUa8p2P7ihKv OTIw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1729615570; x=1730220370; 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=pPeTnArfy3kVD9qdVEi17t1QYmpfbQ/+MP9HcRzS7Mw=; b=N5X9yMNHtdj4b5KUzgYYybV0dlNKYJWZZOZ2HrPDnU8ibSMAIGnb4T9y8vpgQlmjpS nDiK7Jft/ytCrsdUgaNQAEsjUXv16/EWubws20Rl1hKt6DAZapTrcF+g+PKidnHUPnIN ZTuTNY32xl0/69K7aTCl9RcGd4SHyjNaZH7uWCRn6cQuYZC4Hi6yC3OycO275Gkn81Wv dAZVUI0JtZVc7k4zeFwvDqfor3MnnqC5oiZv9XLS45TiTkbnMLMoVzFFBson4z6MEX+V b5luJPukCfH8PV22lRvko338HNB7WT5UBZ5RXg1yHDaZU5V1b2+zLD+1eBamxQEwjgS3 dqgg== X-Forwarded-Encrypted: i=1; AJvYcCXRymY27IdO9dP2DzHj8dJ83z93qT8wXHIi5th+2P6ritGRq/nM+EpC9pipKBP2WHzDITlP+vfTtbS+J0zotp49@lists.infradead.org X-Gm-Message-State: AOJu0YzbrmIRjX7GhlPGFzvABBLVwQ1g7FUAUJ1AyEQzMedlNbOcFxuj Tw4k7bs/KfRO2qFBJH3Ix98vHrRQHyHP199LvbvpfxWuYSlZPvEtJUcjRrjRgQ== X-Google-Smtp-Source: AGHT+IHTS9yyMdGSpDBkN1ZywG4L881bK6lpw9juFK/sdg8K6E7YS49sKlIWRIuG+HaxSkMO8HbgaA== X-Received: by 2002:aa7:88d4:0:b0:71e:b8:1930 with SMTP id d2e1a72fcca58-71ea321e7famr21475298b3a.16.1729615569937; Tue, 22 Oct 2024 09:46:09 -0700 (PDT) Received: from thinkpad ([36.255.17.224]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-71ec13336d1sm4966249b3a.56.2024.10.22.09.46.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 22 Oct 2024 09:46:09 -0700 (PDT) Date: Tue, 22 Oct 2024 22:16:03 +0530 From: Manivannan Sadhasivam To: Richard Zhu Cc: kw@linux.com, bhelgaas@google.com, lpieralisi@kernel.org, frank.li@nxp.com, l.stach@pengutronix.de, robh+dt@kernel.org, conor+dt@kernel.org, shawnguo@kernel.org, krzysztof.kozlowski+dt@linaro.org, festevam@gmail.com, s.hauer@pengutronix.de, linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, kernel@pengutronix.de, imx@lists.linux.dev Subject: Re: [PATCH v4 2/9] PCI: imx6: Add ref clock for i.MX95 PCIe Message-ID: <20241022164603.gndz4vgbm2sgwtfj@thinkpad> References: <1728981213-8771-1-git-send-email-hongxing.zhu@nxp.com> <1728981213-8771-3-git-send-email-hongxing.zhu@nxp.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1728981213-8771-3-git-send-email-hongxing.zhu@nxp.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241022_094611_460086_8B4577FA X-CRM114-Status: GOOD ( 19.32 ) 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 Tue, Oct 15, 2024 at 04:33:26PM +0800, Richard Zhu wrote: > Add "ref" clock to enable reference clock. > > If use external clock, ref clock should point to external reference. > > If use internal clock, CREF_EN in LAST_TO_REG controls reference output, > which implement in drivers/clk/imx/clk-imx95-blk-ctl.c. > So this means the driver won't work with old devicetrees. Am I right? Then you are breaking the DT compatibility. You should make the clock optional in the driver. - Mani > Signed-off-by: Richard Zhu > Reviewed-by: Frank Li > --- > drivers/pci/controller/dwc/pci-imx6.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/drivers/pci/controller/dwc/pci-imx6.c b/drivers/pci/controller/dwc/pci-imx6.c > index 808d1f105417..52a8b2dc828a 100644 > --- a/drivers/pci/controller/dwc/pci-imx6.c > +++ b/drivers/pci/controller/dwc/pci-imx6.c > @@ -1480,6 +1480,7 @@ static const char * const imx8mm_clks[] = {"pcie_bus", "pcie", "pcie_aux"}; > static const char * const imx8mq_clks[] = {"pcie_bus", "pcie", "pcie_phy", "pcie_aux"}; > static const char * const imx6sx_clks[] = {"pcie_bus", "pcie", "pcie_phy", "pcie_inbound_axi"}; > static const char * const imx8q_clks[] = {"mstr", "slv", "dbi"}; > +static const char * const imx95_clks[] = {"pcie_bus", "pcie", "pcie_phy", "pcie_aux", "ref"}; > > static const struct imx_pcie_drvdata drvdata[] = { > [IMX6Q] = { > @@ -1593,8 +1594,8 @@ static const struct imx_pcie_drvdata drvdata[] = { > [IMX95] = { > .variant = IMX95, > .flags = IMX_PCIE_FLAG_HAS_SERDES, > - .clk_names = imx8mq_clks, > - .clks_cnt = ARRAY_SIZE(imx8mq_clks), > + .clk_names = imx95_clks, > + .clks_cnt = ARRAY_SIZE(imx95_clks), > .ltssm_off = IMX95_PE0_GEN_CTRL_3, > .ltssm_mask = IMX95_PCIE_LTSSM_EN, > .mode_off[0] = IMX95_PE0_GEN_CTRL_1, > -- > 2.37.1 > -- மணிவண்ணன் சதாசிவம்