old mode 100644
new mode 100755
@@ -1393,10 +1393,14 @@ static void pci_add_loc_code(struct dt_node *np, struct pci_device *pd)
uint8_t pos, len;
while (p) {
- /* if we have a slot label (i.e. openpower) use that */
- blcode = dt_prop_get_def(p, "ibm,slot-label", NULL);
- if (blcode)
- break;
+ /* BMC platforms will favor slot-label, while FSP platforms will
+ * prefer slot-location-code
+ */
+ if (platform.bmc) {
+ blcode = dt_prop_get_def(p, "ibm,slot-label", NULL);
+ if (blcode)
+ break;
+ }
/* otherwise use the fully qualified location code */
blcode = dt_prop_get_def(p, "ibm,slot-location-code", NULL);
FSP Systems will favor fully-qualified "ibm,slot-location-codes" (e.g. "UOPWR.001.XYZ0000-P1-C2" over "ibm,slot-label" (e.g. "C2") for it's "ibm,loc-code" property on pci devices. Signed-off-by: Klaus Heinrich Kiwi <klaus@linux.vnet.ibm.com> --- core/pci.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) mode change 100644 => 100755 core/pci.c