]> git.baikalelectronics.ru Git - kernel.git/commit
ACPI/IORT: Fix rc_dma_get_range()
authorJean-Philippe Brucker <jean-philippe.brucker@arm.com>
Thu, 10 Jan 2019 18:41:51 +0000 (18:41 +0000)
committerWill Deacon <will.deacon@arm.com>
Fri, 11 Jan 2019 10:02:59 +0000 (10:02 +0000)
commitbbb8e4b8fef80a41378c2071b6ff27e91d9bd2ed
tree899581bf6239c72d86a0f14f98c7843fda398907
parent46a4faa0b72ce3f2d6e561f1a3376348a3a3f027
ACPI/IORT: Fix rc_dma_get_range()

When executed for a PCI_ROOT_COMPLEX type, iort_match_node_callback()
expects the opaque pointer argument to be a PCI bus device. At the
moment rc_dma_get_range() passes the PCI endpoint instead of the bus,
and we've been lucky to have pci_domain_nr(ptr) return 0 instead of
crashing. Pass the bus device to iort_scan_node().

Fixes: 1841e971ed83 ("ACPI/IORT: Support address size limit for root complexes")
Reported-by: Eric Auger <eric.auger@redhat.com>
Signed-off-by: Jean-Philippe Brucker <jean-philippe.brucker@arm.com>
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Reviewed-by: Eric Auger <eric.auger@redhat.com>
Acked-by: Robin Murphy <robin.murphy@arm.com>
Cc: stable@vger.kernel.org
Cc: Will Deacon <will.deacon@arm.com>
Cc: Hanjun Guo <hanjun.guo@linaro.org>
Cc: Sudeep Holla <sudeep.holla@arm.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Signed-off-by: Will Deacon <will.deacon@arm.com>
drivers/acpi/arm64/iort.c