ACPI/IORT: Add msi address regions reservation helper
authorShameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Tue, 13 Feb 2018 15:20:50 +0000 (15:20 +0000)
committerJoerg Roedel <jroedel@suse.de>
Wed, 14 Feb 2018 14:15:41 +0000 (15:15 +0100)
commit8b4282e6b8e239d8ce68ab884c89335cc6fdd7c7
tree782cac410eacd34f3a7ebcdb2ef448e7466babdb
parent193e67c00e33e188d68815fb78806317c77f156c
ACPI/IORT: Add msi address regions reservation helper

On some platforms msi parent address regions have to be excluded from
normal IOVA allocation in that they are detected and decoded in a HW
specific way by system components and so they cannot be considered normal
IOVA address space.

Add a helper function that retrieves ITS address regions - the msi
parent - through IORT device <-> ITS mappings and reserves it so that
these regions will not be translated by IOMMU and will be excluded from
IOVA allocations. The function checks for the smmu model number and
only applies the msi reservation if the platform requires it.

Signed-off-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Reviewed-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
[For the ITS part]
Reviewed-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/acpi/arm64/iort.c
drivers/irqchip/irq-gic-v3-its.c
include/linux/acpi_iort.h