diff options
author | Alpana Kumari <alpankum@in.ibm.com> | 2017-08-04 02:26:59 -0500 |
---|---|---|
committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2017-08-07 11:09:25 -0400 |
commit | 3da96b958d3b248737febeb85951a0e446787d07 (patch) | |
tree | eaf6872cade6c1c3365415d47d39064b26829847 /src/usr/targeting/common/processMrw.pl | |
parent | 791dd3b0dc7f228723532e1080b30766eb4d3f1d (diff) | |
download | talos-hostboot-3da96b958d3b248737febeb85951a0e446787d07.tar.gz talos-hostboot-3da96b958d3b248737febeb85951a0e446787d07.zip |
Added FSP support in processMrw
Support for fsp targets apss, dpss, pnor fsi psi and clocks
merged all target_types files to create a single xml and use that as
a reference in filter_out_unwanted_attributes script
Change-Id: I3f61aef0268b45952b94c8bd9ae547718a4fc779
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/44205
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Reviewed-by: Douglas Schwanke <dschwank@us.ibm.com>
Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com>
Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com>
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Prachi Gupta <pragupta@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/targeting/common/processMrw.pl')
-rwxr-xr-x | src/usr/targeting/common/processMrw.pl | 44 |
1 files changed, 42 insertions, 2 deletions
diff --git a/src/usr/targeting/common/processMrw.pl b/src/usr/targeting/common/processMrw.pl index 6523895a7..4bf640950 100755 --- a/src/usr/targeting/common/processMrw.pl +++ b/src/usr/targeting/common/processMrw.pl @@ -42,11 +42,13 @@ my $version = 0; my $debug = 0; my $report = 0; my $sdr_file = ""; +my $build = "hb"; # TODO RTC:170860 - Remove this after dimm connector defines VDDR_ID my $num_voltage_rails_per_proc = 1; GetOptions( + "build=s" => \$build, "f" => \$force, # numeric "x=s" => \$serverwiz_file, # string "d" => \$debug, @@ -81,6 +83,13 @@ $targetObj->setVersion($VERSION); my $xmldir = dirname($serverwiz_file); $targetObj->loadXML($serverwiz_file); +our %hwsvmrw_plugins; +# FSP-specific functions +if ($build eq "fsp") +{ + eval ("use processMrw_fsp; return 1;"); + processMrw_fsp::return_plugins(); +} my $str=sprintf( " %30s | %10s | %6s | %4s | %9s | %4s | %4s | %4s | %10s | %s\n", @@ -107,6 +116,10 @@ foreach my $target (sort keys %{ $targetObj->getAllTargets() }) elsif ($type eq "PROC") { processProcessor($targetObj, $target); + if ($build eq "fsp") + { + do_plugin("fsp_proc", $targetObj, $target); + } } elsif ($type eq "APSS") { @@ -120,6 +133,10 @@ foreach my $target (sort keys %{ $targetObj->getAllTargets() }) processIpmiSensors($targetObj,$target); } +if ($build eq "fsp") +{ + processMrw_fsp::loadFSP($targetObj); +} ## check topology foreach my $n (keys %{$targetObj->{TOPOLOGY}}) { foreach my $p (keys %{$targetObj->{TOPOLOGY}->{$n}}) { @@ -145,10 +162,17 @@ foreach my $target (keys %{ $targetObj->getAllTargets() }) #-------------------------------------------------- ## write out final XML my $xml_fh; -my $filename = $xmldir . "/" . $targetObj->getSystemName() . "_hb.mrw.xml"; +my $filename; +if ( $build eq "fsp" ){ + $filename = $xmldir . "/" . $targetObj->getSystemName() . "_fsp.mrw.xml"; +} +else{ + $filename = $xmldir . "/" . $targetObj->getSystemName() . "_hb.mrw.xml"; +} print "Creating XML: $filename\n"; open($xml_fh, ">$filename") || die "Unable to create: $filename"; -$targetObj->printXML($xml_fh, "top"); + +$targetObj->printXML($xml_fh, "top", $build); close $xml_fh; if (!$targetObj->{errorsExist}) { @@ -1951,3 +1975,19 @@ Options: "; exit(1); } +################################################################################ +# utility function used to call plugins. if none exists, call is skipped. +################################################################################ + +sub do_plugin +{ + my $step = shift; + if (exists($hwsvmrw_plugins{$step})) + { + $hwsvmrw_plugins{$step}(@_); + } + elsif ($debug && ($build eq "fsp")) + { + print STDERR "build is $build but no plugin for $step\n"; + } +} |