diff options
author | Michael Neuling <mikey@neuling.org> | 2017-07-26 20:50:07 +1000 |
---|---|---|
committer | Stewart Smith <stewart@linux.vnet.ibm.com> | 2017-07-28 14:03:59 +1000 |
commit | 0ff4be995e2fa4e36df3bcb42102cbbb37d68fcb (patch) | |
tree | 9a5162e35e7fc7177448cc8454ff37bca8345405 /hw | |
parent | b7f026767be406a9ddba73f7fe58a8d318305c1c (diff) | |
download | skiboot-0ff4be995e2fa4e36df3bcb42102cbbb37d68fcb.zip skiboot-0ff4be995e2fa4e36df3bcb42102cbbb37d68fcb.tar.gz skiboot-0ff4be995e2fa4e36df3bcb42102cbbb37d68fcb.tar.bz2 |
phb4: Simplify calling phb4_eeh_dump_regs()
Do verbose eeh check in phb4_eeh_dump_regs() rather than callers.
Signed-off-by: Michael Neuling <mikey@neuling.org>
Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/phb4.c | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -1901,6 +1901,9 @@ static void phb4_eeh_dump_regs(struct phb4 *p) uint32_t reg; unsigned int i; + if (!verbose_eeh) + return; + s = zalloc(sizeof(struct OpalIoPhb4ErrorData)); phb4_read_phb_status(p, s); @@ -2305,8 +2308,7 @@ static bool phb4_fenced(struct phb4 *p) p->flags |= PHB4_AIB_FENCED; p->state = PHB4_STATE_FENCED; - if (verbose_eeh) - phb4_eeh_dump_regs(p); + phb4_eeh_dump_regs(p); return true; } @@ -3207,7 +3209,7 @@ static int64_t phb4_get_diag_data(struct phb *phb, phb4_fenced(p); phb4_read_phb_status(p, data); - if (verbose_eeh && !(p->flags & PHB4_AIB_FENCED)) + if (!(p->flags & PHB4_AIB_FENCED)) phb4_eeh_dump_regs(p); /* |