acpi: Add addr offset in build_crs
commite41ee855283b79dfd0734e573e9b8d091070190b
authorJiahui Cen <cenjiahui@huawei.com>
Thu, 14 Jan 2021 10:06:38 +0000 (14 18:06 +0800)
committerMichael S. Tsirkin <mst@redhat.com>
Sun, 17 Jan 2021 11:42:54 +0000 (17 06:42 -0500)
treef04368824e89a9cc9cea81ed42cedf0d16d86498
parent4c4465ff1cddc2543abf5ee4c2e4c283cace6da0
acpi: Add addr offset in build_crs

AML needs Address Translation offset to describe how a bridge translates
addresses accross the bridge when using an address descriptor, and
especially on ARM, the translation offset of pio resource is usually
non zero.

Therefore, it's necessary to pass offset for pio, mmio32, mmio64 and bus
number into build_crs.

Acked-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Jiahui Cen <cenjiahui@huawei.com>
Message-Id: <20210114100643.10617-4-cenjiahui@huawei.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/acpi/aml-build.c
hw/i386/acpi-build.c
hw/pci-host/gpex-acpi.c
include/hw/acpi/aml-build.h