aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVasant Hegde <hegdevasant@linux.vnet.ibm.com>2020-04-13 22:03:36 +0530
committerOliver O'Halloran <oohall@gmail.com>2020-04-15 14:05:53 +1000
commit9547b3da44d546f0083dd3aeb5436226fccf81e3 (patch)
treefcd235a24d993cd7f4b9e3946a70d517f7d043bd
parent346647465ab3f3b78c6729857fe3bee2d70ee0cd (diff)
downloadskiboot-9547b3da44d546f0083dd3aeb5436226fccf81e3.zip
skiboot-9547b3da44d546f0083dd3aeb5436226fccf81e3.tar.gz
skiboot-9547b3da44d546f0083dd3aeb5436226fccf81e3.tar.bz2
ZZ: Fix System Attention Indicator location code
We are using SAI indicator location from SLCA to represent System Attention Indicator location code. In P9, this is mapped to op-panel location code. op-panel has identify and fault LEDs as well. Our SPCN command lists op-panel location code as well. Hence we get below OPAL warning. OPAL msglog: FSPLED: duplicate location code U78D3.001.WT0004T-D1 Because of above issue we are not creating device tree node for D1 identify/fault indicators. We have System Attention Indicator at enclosure level as well.. which is replica of attention indicator in op-panel. Hence use System VPD location code to represent attention indicator. Note that we have dedicated MBOX command to read/update System Attention Indicator which doesn't need location code. Hence we are fine with this change. Signed-off-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com> Signed-off-by: Oliver O'Halloran <oohall@gmail.com>
-rw-r--r--hdata/slca.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/hdata/slca.c b/hdata/slca.c
index dd49335..131e815 100644
--- a/hdata/slca.c
+++ b/hdata/slca.c
@@ -87,6 +87,7 @@ static const struct slca_entry *slca_get_sai_entry(void)
int count;
unsigned int i;
struct HDIF_common_hdr *slca_hdr;
+ uint16_t sai_fru_id = SLCA_SAI_INDICATOR_ID;
slca_hdr = get_hdif(&spira.ntuples.slca, SLCA_HDIF_SIG);
if (!slca_hdr) {
@@ -100,6 +101,9 @@ static const struct slca_entry *slca_get_sai_entry(void)
return NULL;
}
+ if (proc_gen >= proc_gen_p9 && dt_find_by_path(dt_root, "fsps"))
+ sai_fru_id = SLCA_SYSTEM_VPD_ID;
+
for (i = 0; i < count; i++) {
const struct slca_entry *s_entry;
unsigned int entry_sz;
@@ -108,7 +112,7 @@ static const struct slca_entry *slca_get_sai_entry(void)
i, &entry_sz);
if (s_entry &&
VPD_ID(s_entry->fru_id[0],
- s_entry->fru_id[1]) == SLCA_SAI_INDICATOR_ID) {
+ s_entry->fru_id[1]) == sai_fru_id) {
prlog(PR_TRACE, "SLCA: SAI index: 0x%x\n",
s_entry->my_index);
prlog(PR_TRACE, "SLCA: SAI location code: %s\n",