linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
To: Jiaxun Yang <jiaxun.yang@flygoat.com>
Cc: Huacai Chen <chenhuacai@kernel.org>,
	linux-pci@vger.kernel.org, bhelgaas@google.com,
	linux-kernel@vger.kernel.org, kw@linux.com,
	lpieralisi@kernel.org, stable@vger.kernel.org
Subject: Re: [PATCH v2] pci: loongson: Workaround MIPS firmware MRRS settings
Date: Thu, 7 Sep 2023 10:38:05 +0530	[thread overview]
Message-ID: <20230907050805.GA3218@thinkpad> (raw)
In-Reply-To: <6e1bdebf-f335-23a5-c79f-d603c5d0150c@flygoat.com>

On Thu, Sep 07, 2023 at 11:13:00AM +0800, Jiaxun Yang wrote:
> 
> 
> 在 2023/9/7 9:18, Manivannan Sadhasivam 写道:
> [...]
> > Why do you need to walk through every single device instead of just bridges?
> > I'm not the maintainer, but my suggestion is to go for Huacai Chen's solution.
> Hi Mani,
> 
> Thanks for your reply, unfortunately Huacai's solution is impractical in
> this case.
> 
> The problem we have, is firmware (or BIOS) setting improper MRRS for devices
> attached under those bridges. So we have to fix up MRRS for every single
> device.
> We can't iterate child device in bridge quirk because there is no guarantee
> that
> bridge will be probed before  it's child device, partly due to hotplug.
> 

Okay, this clarifies and also warrants improvement in commit message.

You could also use pci_walk_bus() after pci_host_probe() to iterate over the
child devices under root bridge and set MRRS. IMO that would look neat.

- Mani

> This quirk has been in tree for a while, until Huacai refactored it and
> broke some
> systems in 8b3517f88ff2 ("PCI: loongson: Prevent LS7A MRRS increases").
> 
> Also to note that ks_pcie_quirk in drivers/pci/controller/dwc/pci-keystone.c
> uses similar approach.
> > This avoids iterating over bridges/devices two times.
> > 
> > Also, please rename firmware to BIOS, as firmware commonly represents the
> > software running on PCIe endpoint devices.
> Ack, will fix in next reversion.
> 
> Thanks
> - Jiaxun
> > 
> > - Mani
> [...]

-- 
மணிவண்ணன் சதாசிவம்

  reply	other threads:[~2023-09-07  5:08 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-25  6:10 [PATCH v2] pci: loongson: Workaround MIPS firmware MRRS settings Jiaxun Yang
2023-08-06  2:20 ` Jiaxun Yang
2023-08-06 14:30   ` Huacai Chen
2023-08-08  7:38     ` Jiaxun Yang
2023-08-29 12:26       ` Linux regression tracking (Thorsten Leemhuis)
2023-08-31  5:31         ` Jiaxun Yang
2023-08-31  6:22       ` Huacai Chen
2023-08-31  8:58         ` Jiaxun Yang
2023-08-31  9:42           ` Huacai Chen
2023-08-31 10:04             ` Jiaxun Yang
2023-09-06 16:11               ` Jiaxun Yang
2023-09-07  1:18       ` Manivannan Sadhasivam
2023-09-07  3:13         ` Jiaxun Yang
2023-09-07  5:08           ` Manivannan Sadhasivam [this message]
2023-09-20 12:33             ` Linux regression tracking (Thorsten Leemhuis)
2023-10-20 11:04               ` Thorsten Leemhuis
2023-10-22 13:36                 ` Jiaxun Yang
2023-10-22 13:38             ` Jiaxun Yang

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=20230907050805.GA3218@thinkpad \
    --to=manivannan.sadhasivam@linaro.org \
    --cc=bhelgaas@google.com \
    --cc=chenhuacai@kernel.org \
    --cc=jiaxun.yang@flygoat.com \
    --cc=kw@linux.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lpieralisi@kernel.org \
    --cc=stable@vger.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).