linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
To: Jim Quinlan <james.quinlan@broadcom.com>
Cc: Phil Elwell <phil@raspberrypi.com>,
	Nicolas Saenz Julienne <nsaenzjulienne@suse.de>,
	Rob Herring <robh@kernel.org>,
	Florian Fainelli <f.fainelli@gmail.com>,
	"maintainer:BROADCOM BCM7XXX ARM ARCHITECTURE" 
	<bcm-kernel-feedback-list@broadcom.com>,
	"moderated list:BROADCOM BCM2711/BCM2835 ARM ARCHITECTURE" 
	<linux-rpi-kernel@lists.infradead.org>,
	"open list:PCI NATIVE HOST BRIDGE AND ENDPOINT DRIVERS" 
	<linux-pci@vger.kernel.org>
Subject: Re: [PATCH v2] PCI: brcmstb: Restore initial fundamental reset
Date: Mon, 18 Jan 2021 12:40:03 +0000	[thread overview]
Message-ID: <20210118124003.GA12967@e121166-lin.cambridge.arm.com> (raw)
In-Reply-To: <CA+-6iNwH3v78QhQOFpsXfA4hgUo9TXJaF4hy_imA60iQ2a3bMg@mail.gmail.com>

On Thu, Nov 12, 2020 at 01:38:13PM -0500, Jim Quinlan wrote:
> On Thu, Nov 12, 2020 at 12:27 PM Phil Elwell <phil@raspberrypi.com> wrote:
> >
> > Commit 04356ac30771 ("PCI: brcmstb: Add bcm7278 PERST# support")
> > replaced a single reset function with a pointer to one of two
> > implementations, but also removed the call asserting the reset
> > at the start of brcm_pcie_setup. Doing so breaks Raspberry Pis with
> > VL805 XHCI controllers lacking dedicated SPI EEPROMs, which have been
> > used for USB booting but then need to be reset so that the kernel
> > can reconfigure them. The lack of a reset causes the firmware's loading
> > of the EEPROM image to RAM to fail, breaking USB for the kernel.
> >
> > Fixes: commit 04356ac30771 ("PCI: brcmstb: Add bcm7278 PERST# support")
> >
> > Signed-off-by: Phil Elwell <phil@raspberrypi.com>
> > Acked-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> > ---
> > Changes in v2:
> >   - Exclude BCM7278 from the initial reset
> >   - Ack from Nicolas
> > ---
> >  drivers/pci/controller/pcie-brcmstb.c | 5 +++++
> >  1 file changed, 5 insertions(+)
> >
> > diff --git a/drivers/pci/controller/pcie-brcmstb.c b/drivers/pci/controller/pcie-brcmstb.c
> > index bea86899bd5d..83aa85bfe8e3 100644
> > --- a/drivers/pci/controller/pcie-brcmstb.c
> > +++ b/drivers/pci/controller/pcie-brcmstb.c
> > @@ -869,6 +869,11 @@ static int brcm_pcie_setup(struct brcm_pcie *pcie)
> >
> >         /* Reset the bridge */
> >         pcie->bridge_sw_init_set(pcie, 1);
> > +
> > +       /* Assert the fundemental reset, except on BCM7278 */
> > +       if (pcie->type != BCM7278)
> > +               pcie->perst_set(pcie, 1);
> I'm okay with this although I  would rather it not be needed.

Can I merge this patch as is then ?

Thanks,
Lorenzo

> Regards,
> Jim
> > +
> >         usleep_range(100, 200);
> >
> >         /* Take the bridge out of reset */
> > --
> > 2.25.1
> >



  reply	other threads:[~2021-01-18 12:41 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-12 17:27 [PATCH v2] PCI: brcmstb: Restore initial fundamental reset Phil Elwell
2020-11-12 18:05 ` Stefan Wahren
2020-11-12 18:38 ` Jim Quinlan
2021-01-18 12:40   ` Lorenzo Pieralisi [this message]
2021-01-18 12:44     ` Nicolas Saenz Julienne
2021-01-18 13:33       ` Phil Elwell

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=20210118124003.GA12967@e121166-lin.cambridge.arm.com \
    --to=lorenzo.pieralisi@arm.com \
    --cc=bcm-kernel-feedback-list@broadcom.com \
    --cc=f.fainelli@gmail.com \
    --cc=james.quinlan@broadcom.com \
    --cc=linux-pci@vger.kernel.org \
    --cc=linux-rpi-kernel@lists.infradead.org \
    --cc=nsaenzjulienne@suse.de \
    --cc=phil@raspberrypi.com \
    --cc=robh@kernel.org \
    /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;
as well as URLs for NNTP newsgroup(s).