[Skiboot] [RFC PATCH 19/23] hw/phb4: Wire up assert_perst()
Oliver O'Halloran
oohall at gmail.com
Wed Apr 3 20:09:16 AEDT 2019
Signed-off-by: Oliver O'Halloran <oohall at gmail.com>
---
hw/phb4.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/hw/phb4.c b/hw/phb4.c
index 75a1eb45a3d4..02dca9e5238f 100644
--- a/hw/phb4.c
+++ b/hw/phb4.c
@@ -2921,7 +2921,7 @@ static unsigned int phb4_get_max_link_speed(struct phb4 *p, struct dt_node *np)
return max_link_speed;
}
-static void phb4_assert_perst(struct pci_slot *slot, bool assert)
+static int64_t phb4_assert_perst(struct pci_slot *slot, bool assert)
{
struct phb4 *p = phb_to_phb4(slot->phb);
uint16_t linkctl;
@@ -2950,6 +2950,7 @@ static void phb4_assert_perst(struct pci_slot *slot, bool assert)
out_be64(p->regs + PHB_PCIE_CRESET, reg);
phb4_pcicfg_write16(&p->phb, 0, p->ecap + PCICAP_EXP_LCTL, linkctl);
+ return OPAL_SUCCESS;
}
static int64_t phb4_hreset(struct pci_slot *slot)
@@ -3434,6 +3435,7 @@ static struct pci_slot *phb4_slot_create(struct phb *phb)
slot->ops.get_latch_state = NULL;
slot->ops.set_power_state = NULL;
slot->ops.set_attention_state = NULL;
+ slot->ops.assert_perst = phb4_assert_perst;
/*
* For PHB slots, we have to split the fundamental reset
--
2.20.1
More information about the Skiboot
mailing list