[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200610074633.GA6844@myrica>
Date: Wed, 10 Jun 2020 09:46:33 +0200
From: Jean-Philippe Brucker <jean-philippe@...aro.org>
To: Zhangfei Gao <zhangfei.gao@...aro.org>
Cc: Bjorn Helgaas <bhelgaas@...gle.com>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Arnd Bergmann <arnd@...db.de>, kenneth-lee-2012@...mail.com,
Wangzhou <wangzhou1@...ilicon.com>, linux-pci@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [RFC PATCH] PCI: Remove End-End TLP as PASID dependency
On Wed, Jun 10, 2020 at 12:18:14PM +0800, Zhangfei Gao wrote:
> Some platform devices appear as PCI and have PCI cfg space,
> but are actually on the AMBA bus.
> They can support PASID via smmu stall feature, but does not
> support tlp since they are not real pci devices.
> So remove tlp as a PASID dependency.
>
> Signed-off-by: Zhangfei Gao <zhangfei.gao@...aro.org>
> ---
> drivers/pci/ats.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/pci/ats.c b/drivers/pci/ats.c
> index 390e92f..8e31278 100644
> --- a/drivers/pci/ats.c
> +++ b/drivers/pci/ats.c
> @@ -344,9 +344,6 @@ int pci_enable_pasid(struct pci_dev *pdev, int features)
> if (WARN_ON(pdev->pasid_enabled))
> return -EBUSY;
>
> - if (!pdev->eetlp_prefix_path)
> - return -EINVAL;
> -
This check is useful, and follows the PCI specification (4.0r1.0
2.2.10.2 End-End TLP Prefix Processing: "Software should ensure that TLPs
containing End-End TLP Prefixes are not sent to components that do not
support them.")
Why not set the eetlp_prefix_path bit from a PCI quirk? Unlike the stall
problem from the other thread, this one looks like a simple design mistake
that can be fixed easily in future iterations of the platform: just set
the "End-End TLP Prefix Supported" bit in the Device Capability 2 Register
of all bridges.
Thanks,
Jean
Powered by blists - more mailing lists