linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: "Krzysztof Hałasa" <khalasa@piap.pl>
Cc: "Bjorn Helgaas" <bhelgaas@google.com>,
	PCI <linux-pci@vger.kernel.org>,
	"Artem Lapkin" <email2tema@gmail.com>,
	"Neil Armstrong" <narmstrong@baylibre.com>,
	"Huacai Chen" <chenhuacai@gmail.com>,
	"Lorenzo Pieralisi" <lorenzo.pieralisi@arm.com>,
	"Krzysztof Wilczyński" <kw@linux.com>,
	"Richard Zhu" <hongxing.zhu@nxp.com>,
	"Lucas Stach" <l.stach@pengutronix.de>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] PCIe: limit Max Read Request Size on i.MX to 512 bytes
Date: Fri, 13 Aug 2021 08:45:43 -0500	[thread overview]
Message-ID: <CAL_JsqL1bPwbPB-3y6s0d6XoNkjrSzpbx=p7BcTq8UyTbh8pvw@mail.gmail.com> (raw)
In-Reply-To: <m37dgp20cr.fsf@t19.piap.pl>

On Fri, Aug 13, 2021 at 3:52 AM Krzysztof Hałasa <khalasa@piap.pl> wrote:
>
> DWC PCIe controller imposes limits on the Read Request Size that it can
> handle. For i.MX6 family it's fixed at 512 bytes by default.
>
> If a memory read larger than the limit is requested, the CPU responds
> with Completer Abort (CA) (on i.MX6 Unsupported Request (UR) is returned
> instead due to a design error).
>
> The i.MX6 documentation states that the limit can be changed by writing
> to the PCIE_PL_MRCCR0 register, however there is a fixed (and
> undocumented) maximum (CX_REMOTE_RD_REQ_SIZE constant). Tests indicate
> that values larger than 512 bytes don't work, though.
>
> This patch makes the RTL8111 work on i.MX6.
>
> Signed-off-by: Krzysztof Hałasa <khalasa@piap.pl>
>
> diff --git a/drivers/pci/Kconfig b/drivers/pci/Kconfig
> index 0c473d75e625..a11ec93a8cd0 100644
> --- a/drivers/pci/Kconfig
> +++ b/drivers/pci/Kconfig
> @@ -34,6 +34,9 @@ config PCI_DOMAINS_GENERIC
>  config PCI_SYSCALL
>         bool
>
> +config NEED_PCIE_MAX_MRRS

We don't need a config option for this. It's not much code and it will
effectively always be enabled with multi-platform kernels.

Rob

  parent reply	other threads:[~2021-08-13 13:46 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-13  8:52 [PATCH] PCIe: limit Max Read Request Size on i.MX to 512 bytes Krzysztof Hałasa
2021-08-13 10:13 ` Krzysztof Wilczyński
2021-08-13 12:09   ` Krzysztof Hałasa
2021-08-13 19:22     ` Bjorn Helgaas
2021-08-16  5:18       ` Krzysztof Hałasa
2021-08-16  7:49         ` Richard Zhu
2021-08-16 11:18           ` Krzysztof Hałasa
2021-08-13 13:45 ` Rob Herring [this message]
2021-08-13 18:18   ` Krzysztof Hałasa

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='CAL_JsqL1bPwbPB-3y6s0d6XoNkjrSzpbx=p7BcTq8UyTbh8pvw@mail.gmail.com' \
    --to=robh@kernel.org \
    --cc=bhelgaas@google.com \
    --cc=chenhuacai@gmail.com \
    --cc=email2tema@gmail.com \
    --cc=hongxing.zhu@nxp.com \
    --cc=khalasa@piap.pl \
    --cc=kw@linux.com \
    --cc=l.stach@pengutronix.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lorenzo.pieralisi@arm.com \
    --cc=narmstrong@baylibre.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;
as well as URLs for NNTP newsgroup(s).