arm/acpi: fix PCI _PRT definition
commitc77b25315941250163d3c226266db584ebf7f3e8
authorHeyi Guo <guoheyi@huawei.com>
Tue, 4 Feb 2020 01:43:22 +0000 (4 09:43 +0800)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 13 Feb 2020 14:14:53 +0000 (13 14:14 +0000)
tree5f62406ab859ba23a64ddd217a7eb65c0ec01fe3
parent93e41700012525ca198d10c586e024b925779e6d
arm/acpi: fix PCI _PRT definition

The address field in each _PRT mapping package should be constructed
with high word for device# and low word for function#, so it is wrong
to use bus_no as the high word. The existing code adds a bunch useless
entries with device #s above 31. Enumerate all possible slots
(i.e. PCI_SLOT_MAX) instead.

Signed-off-by: Heyi Guo <guoheyi@huawei.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Message-id: 20200204014325.16279-5-guoheyi@huawei.com
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
hw/arm/virt-acpi-build.c