aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilippe Bergheaud <felix@linux.vnet.ibm.com>2016-01-12 10:29:25 +0100
committerStewart Smith <stewart@linux.vnet.ibm.com>2016-01-15 15:04:57 +1100
commit2e4cc4dca8c0d31138adc52076b38d80c5a6bef0 (patch)
treea512a4795a3114a8603da4fc7626e73ebeb64460
parent298192508e12a9714af21230296cd63df343a849 (diff)
downloadskiboot-2e4cc4dca8c0d31138adc52076b38d80c5a6bef0.zip
skiboot-2e4cc4dca8c0d31138adc52076b38d80c5a6bef0.tar.gz
skiboot-2e4cc4dca8c0d31138adc52076b38d80c5a6bef0.tar.bz2
hmi: Identify the phb upon CAPI malfunction alert
Find the phb index with capp_phb3_attached_mask. Signed-off-by: Philippe Bergheaud <felix@linux.vnet.ibm.com> Reviewed-by: Andrew Donnellan <andrew.donnellan@au1.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
-rw-r--r--core/hmi.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/core/hmi.c b/core/hmi.c
index 71a6c7e..d2cca90 100644
--- a/core/hmi.c
+++ b/core/hmi.c
@@ -256,13 +256,15 @@ static int handle_capp_recoverable(int chip_id)
u32 dt_chip_id;
struct phb *phb;
u32 phb_index;
+ struct proc_chip *chip = get_chip(chip_id);
+ u8 mask = chip->capp_phb3_attached_mask;
dt_for_each_compatible(dt_root, np, "ibm,power8-pciex") {
dt_chip_id = dt_prop_get_u32(np, "ibm,chip-id");
phb_index = dt_prop_get_u32(np, "ibm,phb-index");
phb_id = dt_prop_get_u64(np, "ibm,opal-phbid");
- if ((phb_index == 0) && (chip_id == dt_chip_id)) {
+ if ((mask & (1 << phb_index)) && (chip_id == dt_chip_id)) {
phb = pci_get_phb(phb_id);
phb->ops->lock(phb);
phb->ops->set_capp_recovery(phb);