On 19/06/2020 04:00, Barry Song wrote:
Some platform devices like ARM SMMU are memory-mapped and populated by
ACPI/IORT.
In this case, NUMA topology of those platform devices are exported by firmware
as
well. Software might care about the numa_node of those devices in order to
achieve
NUMA locality.
Is it generally the case that the SMMU will be in the same NUMA node as
the endpoint device (which you're driving)? If so, we can get this info
from sysfs already for the endpoint, and also have a link from the
endpoint to the iommu for pci devices (which I assume you're interested in):
root@(none)$ ls -l /sys/devices/pci0000:74/0000:74:02.0/ | grep iommu
lrwxrwxrwx 1 root root 0 Jun 22 10:33 iommu ->
../../platform/arm-smmu-v3.2.auto/iommu/smmu3.0x0000000140000000
lrwxrwxrwx 1 root root 0 Jun 22 10:33 iommu_group ->
../../../kernel/iommu_groups/0
root@(none)$
Thanks,
John