diff mbox series

[6/8] firenze-pci: Always init slot info from LXVPD

Message ID 20190318061058.3753-6-oohall@gmail.com
State Accepted
Headers show
Series [1/8] hdata/iohub: Look for IOVPD on P9 | expand

Checks

Context Check Description
snowpatch_ozlabs/apply_patch success Successfully applied on branch master (2ba5ce84a197ee61423355f443a3ff3eea185ff1)
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot fail Test snowpatch/job/snowpatch-skiboot on branch master
snowpatch_ozlabs/snowpatch_job_snowpatch-skiboot-dco success Signed-off-by present

Commit Message

Oliver O'Halloran March 18, 2019, 6:10 a.m. UTC
We can slot information from the LXVPD without having power control
information about that slot. This patch changes the init path so that
we always override the add_properties() call rather than only when we
have power control information about the slot.

Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
---
 platforms/ibm-fsp/firenze-pci.c | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)
diff mbox series

Patch

diff --git a/platforms/ibm-fsp/firenze-pci.c b/platforms/ibm-fsp/firenze-pci.c
index b87c65bfc082..dc0ff568a385 100644
--- a/platforms/ibm-fsp/firenze-pci.c
+++ b/platforms/ibm-fsp/firenze-pci.c
@@ -879,7 +879,10 @@  static void firenze_pci_slot_init(struct pci_slot *slot)
 	uint32_t vdid;
 	int i;
 
-	/* Search for PCI slot info */
+	/* Init the slot info from the LXVPD */
+	slot->ops.add_properties = lxvpd_add_slot_properties;
+
+	/* Search for power control information in the per-system table */
 	for (i = 0; i < ARRAY_SIZE(firenze_pci_slots); i++) {
 		if (firenze_pci_slots[i].index == s->slot_index &&
 		    !strcmp(firenze_pci_slots[i].label, s->label)) {
@@ -927,13 +930,6 @@  static void firenze_pci_slot_init(struct pci_slot *slot)
 			}
 		}
 	}
-
-	/*
-         * Anyway, the slot has platform specific info. That
-         * requires platform specific method to parse it out
-         * properly.
-         */
-	slot->ops.add_properties = lxvpd_add_slot_properties;
 }
 
 void firenze_pci_setup_phb(struct phb *phb, unsigned int index)