summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPrachi Gupta <pragupta@us.ibm.com>2016-11-14 16:21:59 -0600
committerWilliam G. Hoffa <wghoffa@us.ibm.com>2016-12-05 13:59:16 -0500
commit1ac343bdb0d937b3a4b4c7de1aba03f38bf2ee7f (patch)
tree5ac995d21e713ce6beffb6df4dff3a33f60a490d
parentbf021a35c3333f4193a5342e80f4256628b9241c (diff)
downloadtalos-hostboot-1ac343bdb0d937b3a4b4c7de1aba03f38bf2ee7f.tar.gz
talos-hostboot-1ac343bdb0d937b3a4b4c7de1aba03f38bf2ee7f.zip
Fix i2c scom address math for p9
Change-Id: I7dd49b51f233a7862907f236813f2ed26da455c5 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/32616 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Martin Gloff <mgloff@us.ibm.com> Reviewed-by: Michael Baiocchi <mbaiocch@us.ibm.com> Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
-rwxr-xr-xsrc/usr/i2c/i2c.C5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/usr/i2c/i2c.C b/src/usr/i2c/i2c.C
index eb3fdb6ee..aca89c7a1 100755
--- a/src/usr/i2c/i2c.C
+++ b/src/usr/i2c/i2c.C
@@ -3709,7 +3709,10 @@ void getMasterInfo( const TARGETING::Target* i_chip,
}
MasterInfo_t info;
- info.scomAddr = 0x000A0000 + engine*0x20;
+
+ //For P9, the base scom address for each i2c engine
+ //can be computed by adding an offset of 0x1000 each time
+ info.scomAddr = 0x000A0000 + engine*P9_ENGINE_SCOM_OFFSET;
info.engine = engine;
info.freq = i2cGetNestFreq()*1000*1000; //convert MHz->Hz
// PIB_CLK = NEST_FREQ /4
OpenPOWER on IntegriCloud