mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Siddharth Vadapalli <s-vadapalli@ti.com>
To: Jan Kiszka <jan.kiszka@siemens.com>
Cc: "Lorenzo Pieralisi" <lpieralisi@kernel.org>,
	"Krzysztof Wilczyński" <kw@linux.com>,
	"Rob Herring" <robh@kernel.org>,
	"Bjorn Helgaas" <bhelgaas@google.com>,
	"Kishon Vijay Abraham I" <kishon@kernel.org>,
	"Siddharth Vadapalli" <s-vadapalli@ti.com>,
	"Vignesh Raghavendra" <vigneshr@ti.com>,
	"Nishanth Menon" <nm@ti.com>,
	"linux-pci@vger.kernel.org" <linux-pci@vger.kernel.org>,
	"Linux Kernel Mailing List" <linux-kernel@vger.kernel.org>,
	linux-arm-kernel <linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCH v3] PCI: keystone: Add workaround for Errata #i2037 (AM65x SR 1.0)
Date: Fri, 28 Jun 2024 11:14:05 +0530	[thread overview]
Message-ID: <059a7f46-68ea-4d77-b87a-4d2de1968c66@ti.com> (raw)
In-Reply-To: <7c5b8986-c69f-4ff5-9ed2-b2055ae848c4@siemens.com>

On Thu, Jun 27, 2024 at 03:35:28PM +0200, Jan Kiszka wrote:
> From: Kishon Vijay Abraham I <kishon@ti.com>
> 
> Errata #i2037 in AM65x/DRA80xM Processors Silicon Revision 1.0
> (SPRZ452D_July 2018_Revised December 2019 [1]) mentions when an
> inbound PCIe TLP spans more than two internal AXI 128-byte bursts,
> the bus may corrupt the packet payload and the corrupt data may
> cause associated applications or the processor to hang.
> 
> The workaround for Errata #i2037 is to limit the maximum read
> request size and maximum payload size to 128 Bytes. Add workaround

s/128 Bytes/128 bytes
as indicated by Krzysztof on the v1 patch at:
https://lore.kernel.org/linux-pci/YF2K6+R1P3SNUoo5@rocinante/

> for Errata #i2037 here. The errata and workaround is applicable
> only to AM65x SR 1.0 and later versions of the silicon will have
> this fixed.

[...]

> 
> +	/*
> +	 * Memory transactions fail with PCI controller in AM654 PG1.0
> +	 * when MRRS is set to more than 128 Bytes. Force the MRRS to
> +	 * 128 Bytes in all downstream devices.

s/128 Bytes/128 bytes
as indicated by Krzysztof on the v1 patch at:
https://lore.kernel.org/linux-pci/YF2K6+R1P3SNUoo5@rocinante/

> +	 */
> +	if (pci_match_id(am6_pci_devids, bridge)) {
> +		bridge_dev = pci_get_host_bridge_device(dev);
> +		if (!bridge_dev && !bridge_dev->parent)
> +			return;
> +
> +		ks_pcie = dev_get_drvdata(bridge_dev->parent);
> +		if (!ks_pcie)
> +			return;
> +
> +		val = ks_pcie_app_readl(ks_pcie, PID);
> +		val &= RTL;
> +		val >>= RTL_SHIFT;
> +		if (val != AM6_PCI_PG1_RTL_VER)
> +			return;
> +
> +		if (pcie_get_readrq(dev) > 128) {
> +			dev_info(&dev->dev, "limiting MRRS to 128 bytes\n");

Thank you for adding "bytes" in the above line.

> +			pcie_set_readrq(dev, 128);
> +		}
> +	}
>  }
>  DECLARE_PCI_FIXUP_ENABLE(PCI_ANY_ID, PCI_ANY_ID, ks_pcie_quirk);

Regards,
Siddharth.

      reply	other threads:[~2024-06-28  5:44 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-27 13:35 Jan Kiszka
2024-06-28  5:44 ` Siddharth Vadapalli [this message]

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=059a7f46-68ea-4d77-b87a-4d2de1968c66@ti.com \
    --to=s-vadapalli@ti.com \
    --cc=bhelgaas@google.com \
    --cc=jan.kiszka@siemens.com \
    --cc=kishon@kernel.org \
    --cc=kw@linux.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lpieralisi@kernel.org \
    --cc=nm@ti.com \
    --cc=robh@kernel.org \
    --cc=vigneshr@ti.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

all inboxes | Powered by JetHome®