From: "Christian König" <ckoenig.leichtzumerken@gmail.com>
To: linux-pci@vger.kernel.org
Cc: "Kuehling, Felix" <Felix.Kuehling@amd.com>
Subject: Re: [PATCH] PCI: revert "Enable PASID only when ACS RR & UF enabled on upstream path"
Date: Wed, 11 Jan 2023 10:15:58 +0100 [thread overview]
Message-ID: <801745b6-3019-daa9-8ede-f4de10c3f64b@gmail.com> (raw)
In-Reply-To: <20230111085745.401710-1-christian.koenig@amd.com>
Forgot to add Felix as CC as well.
Am 11.01.23 um 09:57 schrieb Christian König:
> This reverts commit 201007ef707a8bb5592cd07dd46fc9222c48e0b9.
>
> It's correct that the PCIe fabric routes Memory Requests based on the
> TLP address, but enabling the PASID mapping doesn't necessary mean that
> Memory Requests will have a PASID associated with them.
>
> The alternative is ATS which lets the device resolve the PASID+addr pair
> before a memory request is made into a routeable TLB address through the
> TA. Those resolved addresses are then cached on the device instead of
> in the IOMMU TLB.
>
> So the assumption that you mandatory need ACS to enabled PASID handling
> on a device is simply not correct, we need to take ATS into account as
> well.
>
> The patch caused failures with AMDs integrated GPUs because some of them
> only enable ATS but not ACS.
>
> For now just revert the patch until this is completely solved.
>
> CC: Jason Gunthorpe <jgg@nvidia.com>
> CC: Kevin Tian <kevin.tian@intel.com>
> CC: Lu Baolu <baolu.lu@linux.intel.com>
> CC: Bjorn Helgaas <bhelgaas@google.com>
> CC: Tony Zhu <tony.zhu@intel.com>
> CC: Joerg Roedel <jroedel@suse.de>
> Signed-off-by: Christian König <christian.koenig@amd.com>
> Bug: https://bugzilla.kernel.org/show_bug.cgi?id=216865
> ---
> drivers/pci/ats.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/pci/ats.c b/drivers/pci/ats.c
> index f9cc2e10b676..c967ad6e2626 100644
> --- a/drivers/pci/ats.c
> +++ b/drivers/pci/ats.c
> @@ -382,9 +382,6 @@ int pci_enable_pasid(struct pci_dev *pdev, int features)
> if (!pasid)
> return -EINVAL;
>
> - if (!pci_acs_path_enabled(pdev, NULL, PCI_ACS_RR | PCI_ACS_UF))
> - return -EINVAL;
> -
> pci_read_config_word(pdev, pasid + PCI_PASID_CAP, &supported);
> supported &= PCI_PASID_CAP_EXEC | PCI_PASID_CAP_PRIV;
>
next prev parent reply other threads:[~2023-01-11 9:18 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-11 8:57 [PATCH] PCI: revert "Enable PASID only when ACS RR & UF enabled on upstream path" Christian König
2023-01-11 9:15 ` Christian König [this message]
2023-01-11 10:04 ` Linux kernel regression tracking (Thorsten Leemhuis)
2023-01-11 13:07 ` Jason Gunthorpe
2023-01-11 13:38 ` Christian König
2023-01-11 13:44 ` Jason Gunthorpe
2023-01-11 13:54 ` Baolu Lu
2023-01-11 14:14 ` Jason Gunthorpe
2023-01-11 14:17 ` Christian König
2023-01-11 14:20 ` Jason Gunthorpe
2023-01-11 14:24 ` Christian König
2023-01-12 8:59 ` Baolu Lu
[not found] ` <41e25f9f-b106-de77-97ab-d50196de7514@amd.com>
2023-01-11 14:36 ` Jason Gunthorpe
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=801745b6-3019-daa9-8ede-f4de10c3f64b@gmail.com \
--to=ckoenig.leichtzumerken@gmail.com \
--cc=Felix.Kuehling@amd.com \
--cc=linux-pci@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