Skip to content

Commit ae9813d

Browse files
houlz0507robherring
authored andcommitted
PCI: Add quirks to generate device tree node for Xilinx Alveo U50
The Xilinx Alveo U50 PCI card exposes multiple hardware peripherals on its PCI BAR. The card firmware provides a flattened device tree to describe the hardware peripherals on its BARs. This allows U50 driver to load the flattened device tree and generate the device tree node for hardware peripherals underneath. To generate device tree node for U50 card, add PCI quirks to call of_pci_make_dev_node() for U50. Acked-by: Bjorn Helgaas <[email protected]> Signed-off-by: Lizhi Hou <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Rob Herring <[email protected]>
1 parent 407d1a5 commit ae9813d

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

drivers/pci/quirks.c

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6138,3 +6138,14 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x9a2d, dpc_log_size);
61386138
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x9a2f, dpc_log_size);
61396139
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, 0x9a31, dpc_log_size);
61406140
#endif
6141+
6142+
/*
6143+
* For a PCI device with multiple downstream devices, its driver may use
6144+
* a flattened device tree to describe the downstream devices.
6145+
* To overlay the flattened device tree, the PCI device and all its ancestor
6146+
* devices need to have device tree nodes on system base device tree. Thus,
6147+
* before driver probing, it might need to add a device tree node as the final
6148+
* fixup.
6149+
*/
6150+
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_XILINX, 0x5020, of_pci_make_dev_node);
6151+
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_XILINX, 0x5021, of_pci_make_dev_node);

0 commit comments

Comments
 (0)