public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Helgaas <helgaas@kernel.org>
To: Christian Marangi <ansuelsmth@gmail.com>
Cc: "Stanimir Varbanov" <svarbanov@mm-sol.com>,
	"Andy Gross" <agross@kernel.org>,
	"Bjorn Andersson" <bjorn.andersson@linaro.org>,
	"Konrad Dybcio" <konrad.dybcio@somainline.org>,
	"Lorenzo Pieralisi" <lpieralisi@kernel.org>,
	"Rob Herring" <robh@kernel.org>,
	"Krzysztof Wilczyński" <kw@linux.com>,
	"Bjorn Helgaas" <bhelgaas@google.com>,
	linux-pci@vger.kernel.org, linux-arm-msm@vger.kernel.org,
	linux-kernel@vger.kernel.org,
	"Robert Marko" <robimarko@gmail.com>
Subject: Re: [PATCH] PCI: qcom: Enable clocks only after PARF_PHY setup for rev 2.1.0
Date: Mon, 11 Jul 2022 14:22:29 -0500	[thread overview]
Message-ID: <20220711192229.GA678639@bhelgaas> (raw)
In-Reply-To: <62c8d3e8.1c69fb81.26eee.0249@mx.google.com>

[+cc Robert since I resolved a conflict in his patch, -cc stable]

On Sat, Jul 09, 2022 at 03:03:34AM +0200, Christian Marangi wrote:
> On Fri, Jul 08, 2022 at 06:01:55PM -0500, Bjorn Helgaas wrote:
> > On Sat, Jul 09, 2022 at 12:27:43AM +0200, Christian Marangi wrote:
> > > We currently enable clocks BEFORE we write to PARF_PHY_CTRL reg to
> > > enable clocks and resets. This case the driver to never set to a ready
> > > state with the error 'Phy link never came up'.
> > > 
> > > This in fact is caused by the phy clock getting enabled before setting
> > > the required bits in the PARF regs.
> > > 
> > > A workaround for this was set but with this new discovery we can drop
> > > the workaround and use a proper solution to the problem by just enabling
> > > the clock only AFTER the PARF_PHY_CTRL bit is set.
> > > 
> > > This correctly setup the pcie line and makes it usable even when a
> > > bootloader leave the pcie line to a underfined state.
> > 
> > Is "pcie" here a signal name?  Maybe this refers to the "PCIe link"?
> 
> no i was referring to PCIe link. Fell free to fix it if it's not a
> problem (or if you want i can just resend)

I fixed it.

> Think something went wrong in the rebase as the patch fixup is reverted.
> 
> 11946f8b6e77a6794c111aafef7772e9967d9a54 is still wrong.
> 
> clk_bulk_prepare_enable must be after 
> writel(val, pcie->parf + PCIE20_PARF_PHY_CTRL);
> so in the post init.

My error, sorry.  I updated it, current head:

  1a88605a3efd ("dt-bindings: PCI: qcom: Fix description typo")

Robert, your patch that I updated is:

https://git.kernel.org/pub/scm/linux/kernel/git/helgaas/pci.git/commit/?h=pci/ctrl/qcom-pending&id=cdb32283bcf202d0db512abb80794056d44e7e9f

It would still be nice to get an ack from one of the maintainers for
this.

Bjorn

  reply	other threads:[~2022-07-11 19:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-08 22:27 [PATCH] PCI: qcom: Enable clocks only after PARF_PHY setup for rev 2.1.0 Christian Marangi
2022-07-08 23:01 ` Bjorn Helgaas
2022-07-09  1:03   ` Christian Marangi
2022-07-11 19:22     ` Bjorn Helgaas [this message]
2022-07-11 21:13       ` Robert Marko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220711192229.GA678639@bhelgaas \
    --to=helgaas@kernel.org \
    --cc=agross@kernel.org \
    --cc=ansuelsmth@gmail.com \
    --cc=bhelgaas@google.com \
    --cc=bjorn.andersson@linaro.org \
    --cc=konrad.dybcio@somainline.org \
    --cc=kw@linux.com \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lpieralisi@kernel.org \
    --cc=robh@kernel.org \
    --cc=robimarko@gmail.com \
    --cc=svarbanov@mm-sol.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox