summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAndrew Geissler <andrewg@us.ibm.com>2016-05-27 13:45:59 -0500
committerWilliam G. Hoffa <wghoffa@us.ibm.com>2016-06-06 09:26:59 -0400
commit140f5561bedb332c37ead282413a078114f0a637 (patch)
treeb8ca4ff44550124e02b0d354bc392155057fa82f /src
parent26900423db39e0c9a20028d92ba4d9dd80ab0b8e (diff)
downloadtalos-hostboot-140f5561bedb332c37ead282413a078114f0a637.tar.gz
talos-hostboot-140f5561bedb332c37ead282413a078114f0a637.zip
X-BUS PEER_TARGET and PEER_HUID support
Change-Id: I75f186522b616cb6a1f8dffa8d9fef02b2f077b1 RTC: 154376 CMVC-Prereq:996492 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/25134 Tested-by: Jenkins Server Tested-by: FSP CI Jenkins Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com> Reviewed-by: Michael Baiocchi <mbaiocch@us.ibm.com> Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com>
Diffstat (limited to 'src')
-rwxr-xr-xsrc/usr/targeting/common/genHwsvMrwXml.pl46
1 files changed, 46 insertions, 0 deletions
diff --git a/src/usr/targeting/common/genHwsvMrwXml.pl b/src/usr/targeting/common/genHwsvMrwXml.pl
index 2ea18c684..a8cf9557c 100755
--- a/src/usr/targeting/common/genHwsvMrwXml.pl
+++ b/src/usr/targeting/common/genHwsvMrwXml.pl
@@ -4468,6 +4468,33 @@ sub generate_xbus
my $fapi_name = sprintf("pu.xbus:k0:n%d:s0:p%02d:c%d", $node, $proc, $xbus);
my $affinityPath = "affinity:sys-$sys/node-$node/proc-$proc/xbus-$xbus";
+ # Peer target variables
+ my $peer;
+ my $p_proc;
+ my $p_port;
+ my $p_node;
+
+ # See if this bus is connected to anything
+ foreach my $pbus ( @pbus )
+ {
+ if ($pbus->[PBUS_FIRST_END_POINT_INDEX] eq
+ "n${node}:p${proc}:x${xbus}" )
+ {
+ if ($pbus->[PBUS_SECOND_END_POINT_INDEX] ne "invalid")
+ {
+ $peer = 1;
+ $p_proc = $pbus->[PBUS_SECOND_END_POINT_INDEX];
+ $p_port = $p_proc;
+ $p_node = $pbus->[PBUS_SECOND_END_POINT_INDEX];
+ $p_node =~ s/^n(.*):p.*:.*$/$1/;
+ $p_proc =~ s/^.*:p(.*):.*$/$1/;
+ $p_port =~ s/.*:p.*:.(.*)$/$1/;
+ my $node_config = $pbus->[PBUS_NODE_CONFIG_FLAG];
+ last;
+ }
+ }
+ }
+
print "
<targetInstance>
<id>sys${sys}node${node}proc${proc}xbus$xbus</id>
@@ -4499,6 +4526,25 @@ sub generate_xbus
<default>$xbus</default>
</attribute>";
+ if ($peer)
+ {
+ my $peerPhysPath = "physical:sys-${sys}/node-${p_node}/"
+ ."proc-${p_proc}/xbus-${p_port}";
+ my $peerHuid = sprintf("0x%02X0E%04X",${p_node},
+ $p_proc*MAX_XBUS_PER_PROC + $p_port);
+
+ print "
+ <attribute>
+ <id>PEER_TARGET</id>
+ <default>$peerPhysPath</default>
+ </attribute>
+ <compileAttribute>
+ <id>PEER_HUID</id>
+ <default>${peerHuid}</default>
+ </compileAttribute>";
+
+ }
+
addPervasiveParentLink($sys,$node,$proc,$xbus,"xbus");
calcAndAddFapiPos("xbus",$affinityPath,$xbus,$fapiPosHr);
OpenPOWER on IntegriCloud