summaryrefslogtreecommitdiff
path: root/src/drivers/pcie/generic/chip.h
diff options
context:
space:
mode:
authorCliff Huang <cliff.huang@intel.com>2022-02-23 15:43:32 -0800
committerFelix Held <felix-coreboot@felixheld.de>2022-03-10 23:57:16 +0000
commit5069f6c3c86a03084c7e5c84f99b7f5d36523f29 (patch)
tree43b63d19d9d7395a6f25910703cd9dbf9110a461 /src/drivers/pcie/generic/chip.h
parentce87832c6662f1060855fd82a00c4a8e47758fe6 (diff)
drivers/pcie/generic: Add support to generate code under companion device instead
Only one ACPI device should be added to a PCIe root port. For the root ports which already have device created, the generated code from this driver needs to be merged with the existing device. By default, this driver will create new device named DEV0. This change allows to generate code under an existing device. ex: (generate code under PXSX): Scope (\_SB.PCI0.RP01.PXSX) { Name (_DSD, Package (0x02) // _DSD: Device-Specific Data { ToUUID ("daffd814-6eba-4d8c-8a91-bc9bbf4aa301") Package (0x01) { Package (0x02) { "UntrustedDevice", One } } }) } BUG=b:221250331 BRANCH=firmware-brya-14505.B Signed-off-by: Cliff Huang <cliff.huang@intel.com> Change-Id: I80634bbfc2927f26f2a55a9c244eca517c437079 Reviewed-on: https://review.coreboot.org/c/coreboot/+/62301 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Diffstat (limited to 'src/drivers/pcie/generic/chip.h')
-rw-r--r--src/drivers/pcie/generic/chip.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/drivers/pcie/generic/chip.h b/src/drivers/pcie/generic/chip.h
index 3be57de530..5d762ec250 100644
--- a/src/drivers/pcie/generic/chip.h
+++ b/src/drivers/pcie/generic/chip.h
@@ -7,6 +7,14 @@
struct drivers_pcie_generic_config {
bool is_untrusted;
+ /*
+ * This needs to be pointed to the device instance in the device tree when
+ * there is already a device with the root port so that the ACPI code to be
+ * generated will be added to that existing device.
+ * By default, an ACPI device named 'DEV0' is created under the root port if
+ * this does not reference to a device.
+ */
+ DEVTREE_CONST struct device *companion_dev;
};
#endif /* _PCIE_GENERIC_H_ */