summaryrefslogtreecommitdiffstats
path: root/drivers/pci/probe.c
diff options
context:
space:
mode:
authorMarc Zyngier <maz@kernel.org>2021-09-29 18:38:42 +0200
committerBjorn Helgaas <bhelgaas@google.com>2021-11-04 22:29:31 +0100
commit468c8d52c33271d21aac070ebef9283f302094cc (patch)
tree8618ec7eb0157d4a74fba4227f5b205697c37cef /drivers/pci/probe.c
parentiommu/dart: Exclude MSI doorbell from PCIe device IOVA range (diff)
downloadlinux-468c8d52c33271d21aac070ebef9283f302094cc.tar.xz
linux-468c8d52c33271d21aac070ebef9283f302094cc.zip
PCI: apple: Configure RID to SID mapper on device addition
The Apple PCIe controller doesn't directly feed the endpoint's Requester ID to the IOMMU (DART), but instead maps RIDs onto Stream IDs (SIDs). The DART and the PCIe controller must thus agree on the SIDs that are used for translation (by using the 'iommu-map' property). For this purpose, parse the 'iommu-map' property each time a device gets added, and use the resulting translation to configure the PCIe RID-to-SID mapper. Similarly, remove the translation if/when the device gets removed. This is all driven from a bus notifier which gets registered at probe time. Hopefully this is the only PCI controller driver in the whole system. [bhelgaas: squash indentation from Zhaoyu Liu <zackary.liu.pro@gmail.com>: https://lore.kernel.org/r/20211031135544.GA1616@pc] Link: https://lore.kernel.org/r/20210929163847.2807812-10-maz@kernel.org Tested-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Signed-off-by: Marc Zyngier <maz@kernel.org> Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> Reviewed-by: Sven Peter <sven@svenpeter.dev>
Diffstat (limited to 'drivers/pci/probe.c')
0 files changed, 0 insertions, 0 deletions