diff options
author | Andrew Donnellan <andrew.donnellan@au1.ibm.com> | 2018-03-01 18:57:15 +1100 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2018-03-01 20:17:54 -0600 |
commit | 6b1cdedcef1d3aa0b4eb772228b5c5aad24764dc (patch) | |
tree | 5c3b4ab25352cd8b05fb763f867c34cf61ee0d8c /core | |
parent | 9db58b1e5c031782c442f92775ee75326a7be1b3 (diff) | |
download | talos-skiboot-6b1cdedcef1d3aa0b4eb772228b5c5aad24764dc.tar.gz talos-skiboot-6b1cdedcef1d3aa0b4eb772228b5c5aad24764dc.zip |
npu2-opencapi: Train OpenCAPI links and setup devices
Scan the OpenCAPI links under the NPU, and for each link, reset the card,
set up a device, train the link and register a PHB.
Implement the necessary operations for the OpenCAPI PHB type.
For bringup, test and debug purposes, we allow an NVRAM setting,
"opencapi-link-training" that can be set to either disable link training
completely or to use the prbs31 test pattern.
To disable link training:
nvram -p ibm,skiboot --update-config opencapi-link-training=none
To use prbs31:
nvram -p ibm,skiboot --update-config opencapi-link-training=prbs31
Signed-off-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com>
Signed-off-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Reviewed-by: Frederic Barrat <fbarrat@linux.vnet.ibm.com>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'core')
-rw-r--r-- | core/pci.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -1549,7 +1549,8 @@ static void pci_add_one_device_node(struct phb *phb, pd->dn = np = dt_new(parent_node, name); /* XXX FIXME: make proper "compatible" properties */ - if (pci_has_cap(pd, PCI_CFG_CAP_ID_EXP, false)) { + if (pci_has_cap(pd, PCI_CFG_CAP_ID_EXP, false) || + phb->phb_type == phb_type_npu_v2_opencapi) { snprintf(compat, MAX_NAME, "pciex%x,%x", vdid & 0xffff, vdid >> 16); dt_add_property_cells(np, "ibm,pci-config-space-type", 1); |