summaryrefslogtreecommitdiffstats
path: root/hw/nx-crypto.c
diff options
context:
space:
mode:
authorPridhiviraj Paidipeddi <ppaidipe@linux.vnet.ibm.com>2017-02-21 19:21:13 +0530
committerStewart Smith <stewart@linux.vnet.ibm.com>2017-11-30 23:46:28 -0600
commit78168d1bad23c3877bac284eb7c4b259bc022a38 (patch)
tree7d5b606011ffec94ee1f7c0de75c7f61cabb829b /hw/nx-crypto.c
parent92813a8bf9f3658dac5315c0c02025b74a8b0533 (diff)
downloadblackbird-skiboot-78168d1bad23c3877bac284eb7c4b259bc022a38.tar.gz
blackbird-skiboot-78168d1bad23c3877bac284eb7c4b259bc022a38.zip
NX: Print read xscom config failures.
Currently in NX, only write xscom config failures are tracing. Add trace statements for read xscom config failures too. No functional changes. Signed-off-by: Pridhiviraj Paidipeddi <ppaidipe@linux.vnet.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'hw/nx-crypto.c')
-rw-r--r--hw/nx-crypto.c25
1 files changed, 20 insertions, 5 deletions
diff --git a/hw/nx-crypto.c b/hw/nx-crypto.c
index 96998925..769112fd 100644
--- a/hw/nx-crypto.c
+++ b/hw/nx-crypto.c
@@ -53,8 +53,11 @@ static int nx_cfg_sym(u32 gcid, u64 xcfg)
BUILD_ASSERT(MAX_CHIPS < NX_SYM_CFG_CI_MAX);
rc = xscom_read(gcid, xcfg, &cfg);
- if (rc)
+ if (rc) {
+ prerror("NX%d: ERROR: XSCOM SYM config read failure %d\n",
+ gcid, rc);
return rc;
+ }
ct = GETFIELD(NX_SYM_CFG_CT, cfg);
if (!ct)
@@ -106,8 +109,11 @@ static int nx_cfg_asym(u32 gcid, u64 xcfg)
BUILD_ASSERT(MAX_CHIPS < NX_ASYM_CFG_CI_MAX);
rc = xscom_read(gcid, xcfg, &cfg);
- if (rc)
+ if (rc) {
+ prerror("NX%d: ERROR: XSCOM ASYM config read failure %d\n",
+ gcid, rc);
return rc;
+ }
ct = GETFIELD(NX_ASYM_CFG_CT, cfg);
if (!ct)
@@ -158,8 +164,11 @@ static int nx_cfg_dma(u32 gcid, u64 xcfg)
int rc;
rc = xscom_read(gcid, xcfg, &cfg);
- if (rc)
+ if (rc) {
+ prerror("NX%d: ERROR: XSCOM DMA config read failure %d\n",
+ gcid, rc);
return rc;
+ }
cfg = SETFIELD(NX_DMA_CFG_AES_SHA_MAX_RR, cfg,
AES_SHA_MAX_RR);
@@ -199,8 +208,11 @@ static int nx_cfg_iq(u32 gcid, u64 xcfg)
int rc;
rc = xscom_read(gcid, xcfg, &cfg);
- if (rc)
+ if (rc) {
+ prerror("NX%d: ERROR: XSCOM CRB IQ config read failure %d\n",
+ gcid, rc);
return rc;
+ }
cfg = SETFIELD(NX_CRB_IQ_SYM, cfg, CFG_CRB_IQ_SYM);
cfg = SETFIELD(NX_CRB_IQ_ASYM, cfg, CFG_CRB_IQ_ASYM);
@@ -221,8 +233,11 @@ static int nx_cfg_ee(u32 gcid, u64 xcfg)
int rc;
rc = xscom_read(gcid, xcfg, &cfg);
- if (rc)
+ if (rc) {
+ prerror("NX%d: ERROR: XSCOM EE config read failure %d\n",
+ gcid, rc);
return rc;
+ }
cfg = SETFIELD(NX_EE_CFG_CH7, cfg, EE_CH7);
cfg = SETFIELD(NX_EE_CFG_CH6, cfg, EE_CH6);
OpenPOWER on IntegriCloud