ACPI: scan: Add function to fetch dependent of ACPI device
authorDaniel Scally <djrscally@gmail.com>
Thu, 3 Jun 2021 22:40:03 +0000 (23:40 +0100)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Mon, 7 Jun 2021 14:48:05 +0000 (16:48 +0200)
commitb83e2b306736cb0d108df791fd4ee39f6d52184f
treee00bcf6b0796c06391c931e7452e1adaafa4a4df
parenta9e10e58730432e5de840eb3ddd55c75f29341b3
ACPI: scan: Add function to fetch dependent of ACPI device

In some ACPI tables we encounter, devices use the _DEP method to assert
a dependence on other ACPI devices as opposed to the OpRegions that the
specification intends.

We need to be able to find those devices "from" the dependee, so add
a callback and a wrapper to walk over the acpi_dep_list and return
the dependent ACPI device.

Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Daniel Scally <djrscally@gmail.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/scan.c
include/acpi/acpi_bus.h