summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMark Wenning <wenning@us.ibm.com>2012-02-12 22:59:16 -0600
committerA. Patrick Williams III <iawillia@us.ibm.com>2012-02-29 10:10:31 -0600
commite1ff6eea604a68433f2d228a5700f10ef95da5df (patch)
treec7fafd4d049c6b4afc4630cac146abbf64b7106b /src
parentead0bd637b86cab41036264802c91d4cd906ab44 (diff)
downloadtalos-hostboot-e1ff6eea604a68433f2d228a5700f10ef95da5df.tar.gz
talos-hostboot-e1ff6eea604a68433f2d228a5700f10ef95da5df.zip
Create framework for ISTEP 10, 12, 13
istep framework for istep 10 (sbe_centaur_init) istep 12( mss_volt, etc). istep 13 ( mss_draminit, etc ) Commented out testHWP, not used anymore. Fixed bug in hb-istep for simics fixed review comments Added section in genIstep.pl to generate include/usr/isteps/istepNlist.H ( istep 13 generated using script) NOTE: 10, 11, 12 were partially generated manually, that is why they are not consistent. Change-Id: I28ed8d3e60d2d0438ebe7ca3ed2053c781bc72ed Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/661 Tested-by: Jenkins Server Reviewed-by: Van H. Lee <vanlee@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src')
-rwxr-xr-xsrc/build/simics/hb-simdebug.py10
-rwxr-xr-xsrc/build/tools/genIStep.pl1124
-rw-r--r--src/include/usr/hbotcompid.H5
-rw-r--r--src/include/usr/initservice/initsvcreasoncodes.H8
-rw-r--r--src/include/usr/initservice/isteps_trace.H46
-rw-r--r--src/include/usr/isteps/istep04list.H (renamed from src/include/usr/isteps/istep4list.H)31
-rw-r--r--src/include/usr/isteps/istep10list.H165
-rw-r--r--src/include/usr/isteps/istep11list.H62
-rw-r--r--src/include/usr/isteps/istep12list.H112
-rw-r--r--src/include/usr/isteps/istep13list.H209
-rw-r--r--src/include/usr/isteps/istep_template_list.H77
-rw-r--r--src/include/usr/isteps/istepmasterlist.H40
-rw-r--r--src/makefile3
-rw-r--r--src/usr/hwpf/hwp/dmi_training/dmi_training.C90
-rw-r--r--src/usr/hwpf/hwp/dram_training/dram_training.C815
-rw-r--r--src/usr/hwpf/hwp/dram_training/dram_training.H280
-rw-r--r--src/usr/hwpf/hwp/dram_training/makefile48
-rw-r--r--src/usr/hwpf/hwp/makefile3
-rw-r--r--src/usr/hwpf/hwp/mc_init/makefile50
-rw-r--r--src/usr/hwpf/hwp/mc_init/mc_init.C284
-rw-r--r--src/usr/hwpf/hwp/mc_init/mc_init.H143
-rw-r--r--src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.C188
-rw-r--r--src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.H68
-rw-r--r--src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq_wrap.C138
-rw-r--r--src/usr/hwpf/hwp/sbe_centaur_init/makefile47
-rw-r--r--src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C629
-rw-r--r--src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.H291
-rw-r--r--src/usr/hwpf/hwp/template.C126
-rw-r--r--src/usr/hwpf/hwp/template.H169
-rw-r--r--src/usr/initservice/istepdispatcher/istepdispatcher.C37
30 files changed, 4800 insertions, 498 deletions
diff --git a/src/build/simics/hb-simdebug.py b/src/build/simics/hb-simdebug.py
index af1a425c3..5cad5a973 100755
--- a/src/build/simics/hb-simdebug.py
+++ b/src/build/simics/hb-simdebug.py
@@ -269,11 +269,15 @@ def print_istep_list( inList ):
print "IStep\tSubStep\tName"
print "---------------------------------------------------"
for i in range(0,len(inList)) :
+ if ( inList[i][0] != None ) :
+ print "-- %d"%(i)
for j in range( 0, len(inList[i])) :
# print "%d %d"%(i,j)
if ( inList[i][j] != None ) :
- print "%d\t%d\t%s"%( i,j, inList[i][j] )
-
+ ## print "%d\t%d\t%s"%( i,j, inList[i][j] )
+ print "%s"%( inList[i][j] )
+
+
print " "
return None
@@ -409,7 +413,7 @@ def istepHB( symsFile, str_arg1 ):
return;
## start with empty inList. Put some dummy isteps in istep4 for debug.
- n = 10 ## size of inlist array
+ n = 25 ## size of inlist array
inList = [[None]*n for x in xrange(n)] ## init to nothing
inList[4][0] = "i1"
inList[4][1] = "i2"
diff --git a/src/build/tools/genIStep.pl b/src/build/tools/genIStep.pl
new file mode 100755
index 000000000..2cfe2eb7d
--- /dev/null
+++ b/src/build/tools/genIStep.pl
@@ -0,0 +1,1124 @@
+#!/usr/bin/perl
+# IBM_PROLOG_BEGIN_TAG
+# This is an automatically generated prolog.
+#
+# $Source: src/build/tools/genIStep.pl $
+#
+# IBM CONFIDENTIAL
+#
+# COPYRIGHT International Business Machines Corp. 2012
+#
+# p1
+#
+# Object Code Only (OCO) source materials
+# Licensed Internal Code Source Materials
+# IBM HostBoot Licensed Internal Code
+#
+# The source code for this program is not published or other-
+# wise divested of its trade secrets, irrespective of what has
+# been deposited with the U.S. Copyright Office.
+#
+# Origin: 30
+#
+# IBM_PROLOG_END
+
+#
+# Author: Mark Wenning wenning@us.ibm.com
+#
+# Usage:
+# genIStep.pl --tag-file <path> ( required: file containing tag block )
+# [ --help ] ( prints usage message )
+# [ --dry-run ] ( prints all steps without doing anything )
+# [ --import-hwp ] ( import new HWP source from Gerrit )
+#
+# Purpose:
+# Read in a tag file and generate a new istep (or update the existing istep)
+# based on the tags.
+#
+# To set up to run a new HWP, follow these directions
+# ( or have your perlscript do it from the tag block )
+#
+# Make up a new directory src/usr/hwpf/hwp/<@istepname>
+# cd to that directory.
+#
+# Make up a blank file src/usr/hwpf/hwp/<@istepname>/<@istepname.H>
+# (use src/usr/hwpf/hwp/template.H as a template)
+# - add the tag block file detailed below.
+#
+# 1. [x] Update the src/usr/hwpf/hwp/<@istepname>/<@istepname.H>
+# with the prototypes, etc. from the istep/substep.
+#
+# 2. [x] Create a new file src/usr/hwpf/hwp/<@istepname>/<@istepname.C>
+# (use src/usr/hwpf/hwp/template.C as a template)
+#
+# 3. [ ] Make a new istep<@istepnum>list.H file in /usr/include/isteps/
+# Add the new istep<@istepnum>list.H file to
+# src/include/usr/istepmasterlist.H in the correct place in the
+# master istep list.
+#
+# 4. [ ]Make up new makefile src/usr/hwpf/hwp/<@istepname>/makefile to compile
+# the HWP and wrapper
+# Add makefile support for the new HWP:
+# - Scan src/usr/hwpf/hwp/@substepname/makefile for the line:
+# ## NOTE: add a new EXTRAINCDIR when you add a new HWP
+# - Add new line just after it:
+# EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/@istepname/@substepname
+# - Scan further for the line:
+# ## NOTE: add a new directory onto the vpaths when you add a new HWP
+# - Add new line just after it:
+# VPATH += ${ROOTPATH}/src/usr/hwpf/hwp/@istepname/@substepname
+# - Scan further for the line:
+# OBJS = ??
+# - Append $substepname.o on to the end of it. May have to wrap at 80 chars
+#
+# Make sure you add the lines
+# ## pointer to common HWP files
+# EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/include
+# to the makefiles.
+#
+# * Update all the other makefiles:
+# src/usr/hwpf/hwp/makefile ( add SUBDIR )
+# src/usr/hwpf/makefile ( add to HWP_ERROR_XML_FILES, see below )
+# src/usr/makefile ( add to EXTENDED_MODULES )
+#
+
+# Make a new istep<@istepnum>list.H file in /usr/include/isteps/
+# Add the new istep<@istepnum>list.H file to src/include/usr/istepmasterlist.H
+# in the correct place in the master istep list.
+#
+# Create a tag block, usually in src/usr/hwpf/hwp/<@istepname>/<@istepname.H>
+# At present this is optional, but the (coming) genIstep.pl script will
+# not be able to maintain your istep without it.
+#
+# The tag block keywords, with explanations, are as follows:
+# * @tag isteplist
+# - should be at the beginning of the block to tell the (mythical) perl
+# script that this will generate an IStep wrapper for an HWP
+# * @docversion (version # of Dean's IPL document)
+# - adds a comment to istep<@istepname>list.H
+# * @istepname ( istep name from Dean's IPL document )
+# - creates a namespace ISTEP_NAME, i.e. uppercased <@istepame>
+# in <@istepname>.C and <@istepname>.H
+# - creates a new component id in src/include/usr/hbotcompid.H
+# - creates a new module id in src/include/usr/initsvcreasoncodes.H
+# - creates a modulename string "<@istepname>.so" for istep<@istepnum>list.H
+# - ?
+# * @istepnum (istep number from Dean's IPL document)
+# - creates a new istep<@istepnum>list.H file in /usr/include/isteps/
+# - adds the new istep<@istepnum>list.H file to src/include/usr/istepmasterlist.H
+# in the correct place in the master istep list.
+# - sets the istep number in the ISTEPNAME() macro in istep<@istepnum>list.H
+# * @istepdesc ( description of istep from Dean's document )
+# - creates comments in istep<@istepnum>list.H file
+# -- one or more substep blocks:
+# * @substepname (substepname from Dean's document)
+# - creates a prototype for <@substepname>
+# * @substepnum ( number of substep from Dean's document )
+# - sets the istep number in the ISTEPNAME() macro in istep<@istepnum>list.H
+# @target_sched ( serial or parallel )
+# - will attempt to run each target either serially or in parallel
+# -- 0 or more target types to be used as parameters to HWP
+# TBD needs work
+# @target_type (type or class of targets that this HWP should run under)
+# - adds code to find the targets used in TARGETING
+#
+#
+# Make up a new directory src/usr/hwpf/hwp/<@istepname>/<@substepname>
+# Copy code for new HWP to src/usr/hwpf/hwp/<@istepname>/<@substepname>. using git.
+# For example, to set up for istep 11.7, proc_gen_framelock :
+# ## cutNpaste the fetch comand from Gerrit. See the webpage at
+# ## http://gfw160.austin.ibm.com:8080/gerrit/#change,597
+# git fetch ssh://wenning@gfw160.austin.ibm.com:29418/hwp_review_centaur refs/changes/97/597/3
+# ## then run the git command to put the code in the right directory:
+# git diff FETCH_HEAD FETCH_HEAD~1 -R | git apply --directory=src/usr/hwpf/hwp/dmi_training/proc_gen_framelock
+#
+# Add makefile support for the new HWP:
+# - Scan src/usr/hwpf/hwp/@substepname/makefile for the line:
+# ## NOTE: add a new EXTRAINCDIR when you add a new HWP
+# - Add new line just after it:
+# EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/@istepname/@substepname
+# - Scan further for the line:
+# ## NOTE: add a new directory onto the vpaths when you add a new HWP
+# - Add new line just after it:
+# VPATH += ${ROOTPATH}/src/usr/hwpf/hwp/@istepname/@substepname
+# - Scan further for the line:
+# OBJS = ??
+# - Append $substepname.o on to the end of it. May have to wrap at 80 chars
+#
+# Part of the HWP source should (may??) be a <@substep>.xml file .
+# - Update hwpf/makefile to process the xml file in the
+# Source XML files section:
+# #------------------------------------------------------------------------------
+# # Source XML files
+# #------------------------------------------------------------------------------
+# HWP_ERROR_XML_FILES = ...
+#
+
+
+#------------------------------------------------------------------------------
+# Specify perl modules to use
+#------------------------------------------------------------------------------
+use strict;
+use warnings;
+use POSIX;
+use Getopt::Long;
+## use Getopt::Long qw(GetOptionsFromString) ;
+use File::Basename;
+use lib dirname (__FILE__);
+
+
+#------------------------------------------------------------------------------
+# Constants
+#------------------------------------------------------------------------------
+use constant ERR_INVALID_START_TAG => 1;
+use constant ERR_DUPLICATE_TAG => 2;
+use constant ERR_NO_TAG_FILE => 3;
+use constant ERR_NO_ISTEP_DIR => 4;
+use constant ERR_NO_TAG_BLOCK => 5;
+use constant ERR_NO_ISTEP_LIST_DIR => 6;
+
+
+#------------------------------------------------------------------------------
+# Forward Declaration
+#------------------------------------------------------------------------------
+sub printUsage;
+sub extractTagBlock;
+sub processBlock;
+sub storeTagInHash;
+sub createIstepHFile;
+sub createIstepCFile;
+sub createIstepListFile;
+
+#------------------------------------------------------------------------------
+# Globals
+#------------------------------------------------------------------------------
+my %Hash = ();
+my $Tag_Block = "";
+
+#####################################################################
+##### begin templateHFileHdr #################################
+my $templateHFileHdr =
+"
+#ifndef __\@\@istepname_\@\@istepname_H
+#define __\@\@istepname_\@\@istepname_H
+
+/**
+ * \@file \@istepname.H
+ *
+ * \@istepdesc
+ *
+ * All of the following routines are \"named isteps\" - they are invoked as
+ * tasks by the \@ref IStepDispatcher.
+ *
+ * *****************************************************************
+ * THIS FILE WAS GENERATED ON \@timestamp
+ * *****************************************************************
+ *
+ */
+
+/*@
+\@tag_block
+ */
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+namespace \@\@istepname
+{
+";
+##### end templateHFileHdr #################################
+#####################################################################
+
+#####################################################################
+##### begin templateHFileSubStep #############################
+my $templateHFileSubStep =
+"
+/**
+ * \@brief \@substepname
+ *
+ * \@istepnum.\@substepnum : \@substepdesc
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_\@substepname( void * io_pArgs );
+";
+##### end templateHFileSubStep #############################
+#####################################################################
+
+
+#####################################################################
+##### begin templateHFileTrailer ##############################
+my $templateHFileTrailer =
+"
+}; // end namespace
+
+#endif
+";
+##### end templateHFileTrailer #################################
+#####################################################################
+
+
+#####################################################################
+##### begin templateCFileHdr #################################
+my $templateCFileHdr =
+"
+/**
+ * \@file \@istepname.C
+ *
+ * Support file for IStep: \@istepname
+ * \@istepdesc
+ *
+ * *****************************************************************
+ * THIS FILE WAS GENERATED ON \@timestamp
+ * *****************************************************************
+ *
+ */
+
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+#include <trace/interface.H>
+#include <initservice/taskargs.H>
+#include <errl/errlentry.H>
+
+#include <initservice/isteps_trace.H>
+
+// targeting support
+#include <targeting/attributes.H>
+#include <targeting/entitypath.H>
+#include <targeting/target.H>
+#include <targeting/targetservice.H>
+#include <targeting/iterators/rangefilter.H>
+#include <targeting/predicates/predicatectm.H>
+#include <targeting/predicates/predicatepostfixexpr.H>
+#include <targeting/predicates/predicateisfunctional.H>
+
+// fapi support
+#include <fapi.H>
+#include <fapiPlatHwpInvoker.H>
+
+
+// -- prototype includes --
+// Add any customized routines that you don't want overwritten into
+// \"\@istepname_custom.C\" and include the prototypes here.
+// #include \"\@istepname_custom.H\"
+
+#include \"\@istepname.H\"
+
+// Uncomment these files as they become available:
+";
+##### end templateCFileHdr #####################################
+#####################################################################
+
+
+#####################################################################
+##### begin templateCFileNSHdr #####################################
+my $templateCFileNSHdr =
+"
+namespace \@\@istepname
+{
+
+using namespace TARGETING;
+using namespace fapi;
+";
+##### end templateCFileNSHdr #####################################
+#####################################################################
+
+
+#####################################################################
+##### begin templateCFileSubStep #############################
+my $templateCFileSubStep =
+"
+//
+// Wrapper function to call \@istepnum.\@substepnum : \@substepname
+//
+void call_\@substepname( void *io_pArgs )
+{
+ // \@todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, \"call_\@substepname entry\" );
+
+#if 0
+ // \@\@\@\@\@ CUSTOM BLOCK: \@\@\@\@\@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ \"===== \@substepname HWP(? ? ? )\",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_\@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, \"===== \" );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_\@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_\@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = \@substepname( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ \"SUCCESS : \@substepname HWP(? ? ? )\" );
+ }
+ else
+ {
+ /**
+ * \@todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ \"ERROR %d: \@substepname HWP(? ? ?) \",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // \@\@\@\@\@ END CUSTOM BLOCK: \@\@\@\@\@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, \"call_\@substepname exit\" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // \@todo remove when join() merged
+ task_end();
+}
+";
+##### end templateCFileSubStep #################################
+#####################################################################
+
+
+#####################################################################
+##### begin templateCfileTrailer #############################
+my $templateCFileTrailer =
+"
+}; // end namespace
+";
+##### end templateCFileTrailer #############################
+#####################################################################
+
+
+
+#####################################################################
+##### begin templateListFileHdr1 #############################
+my $templateListFileHdr1 =
+"
+#ifndef __ISTEPS_ISTEP\@istepnumLIST_H
+#define __ISTEPS_ISTEP\@istepnumLIST_H
+
+/**
+ * \@file istep\@istepnumlist.H
+ *
+ * IStep \@istepnum \@istepdesc
+ * IPL FLow Doc \@docversion
+ *
+";
+ ##### end templateListFileHdr1 #############################
+#####################################################################
+
+
+#####################################################################
+##### begin templateListFileHdr2 #############################
+ my $templateListFileHdr2 =
+" *
+ * *****************************************************************
+ * THIS FILE WAS GENERATED ON \@timestamp
+ * *****************************************************************
+ *
+ * Please see the note in initsvcstructs.H for description of
+ * the ISTEPNAME macro.
+ *
+ */
+
+#include <initservice/initsvcstructs.H>
+#include <initservice/initsvcreasoncodes.H>
+
+// include prototypes file
+#include \"../../../usr/hwpf/hwp/\@istepname/\@istepname.H\"
+
+namespace INITSERVICE
+{
+ const TaskInfo g_istep\@istepnum[] = {
+ // NOTE: IStep indexes start with 0
+";
+##### end templateListFileHdr2 #############################
+#####################################################################
+
+
+#####################################################################
+##### begin templateListFileSS #################################
+my $templateListFileSS =
+" {
+ ISTEPNAME(\@istepnum,\@-substepnum,\"\@substepname\"),
+ \@\@istepname::call_\@substepname,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+";
+##### end templateListFileSS #############################
+#####################################################################
+
+
+#####################################################################
+##### begin templateListFileTrailer ############################
+my $templateListFileTrailer =
+"
+ // END OF LIST!
+};
+
+// make a struct from the above with the number of items included
+const ExtTaskInfo g_istep\@istepnumTaskList = {
+ &(g_istep\@istepnum[0]),
+ ( sizeof(g_istep\@istepnum)/sizeof(TaskInfo) ),
+ NULL // later, depModules struct
+};
+
+}; // end namespace
+
+#endif
+";
+##### end templateListFileTrailer #############################
+#####################################################################
+
+
+#==============================================================================
+# MAIN
+#==============================================================================
+my $pgmDir = `dirname $0`;
+chomp( $pgmDir );
+
+my $hbDir = $ENV{'HBDIR'};
+if ( ! defined( $hbDir) || ( $hbDir eq "" ) )
+{
+ $hbDir = $pgmDir; ## Set to tool directory
+}
+
+
+## print $#ARGV;
+if ( $#ARGV < 0 )
+{
+ printUsage();
+ exit 0 ;
+}
+#------------------------------------------------------------------------------
+# Parse optional input arguments
+#------------------------------------------------------------------------------
+my $opt_help = 0;
+my $opt_tag_file = "";
+my $opt_dry_run = 0;
+my $opt_debug = 0;
+my $istepDir = "";
+my $istepListDir = "src/include/usr/isteps";
+
+#####
+## This should work, but doesn't.
+## my %optHash = ( 'help|?' => \$opt_help,
+## 'tag-file=s' => \$opt_tag_file,
+## 'dry-run' => \$opt_dry_run,
+## 'debug' => \$opt_debug,
+## );
+## GetOptionsFromArray( \%optHash, \@ARGV,
+## 'help|?',
+## 'debug',
+## 'tag-file=s',
+## 'dry-run'
+## );
+#####
+
+GetOptions( 'help|?' => \$opt_help,
+ 'tag-file=s' => \$opt_tag_file,
+ 'istep-dir=s' => \$istepDir,
+ 'istep-list-dir=s' => \$istepListDir,
+ 'dry-run' => \$opt_dry_run,
+ 'debug' => \$opt_debug,
+ );
+
+if ( $opt_debug )
+{
+ print STDERR "help = $opt_help\n";
+ print STDERR "debug = $opt_debug\n";
+ print STDERR "tag-file = $opt_tag_file\n";
+ print STDERR "dry-run = $opt_dry_run\n";
+ print STDERR "istepDir = $istepDir\n";
+}
+
+
+## check for required options
+if ( $opt_tag_file eq "" )
+{
+ print STDOUT "No tag file specified\n";
+ printUsage();
+ exit ERR_NO_TAG_FILE;
+}
+
+if ( $istepDir eq "" )
+{
+ print STDOUT "No istep-dir specified.\n";
+ exit ERR_NO_ISTEP_DIR;
+}
+
+if ( $istepListDir eq "" )
+{
+ print STDOUT "No istep-list-dir specified.\n";
+ exit ERR_NO_ISTEP_LIST_DIR;
+}
+
+if ( ! -e $opt_tag_file )
+{
+ print STDOUT "Tag file $opt_tag_file doesn't exist\n";
+ exit ERR_NO_TAG_FILE;
+}
+
+if ( ( ! -e $istepDir )
+ || ( ! -d $istepDir )
+ )
+{
+ print STDOUT "dir $istepDir doesn't exist.\n";
+ exit ERR_NO_ISTEP_DIR;
+}
+
+if ( ( ! -e $istepListDir )
+ || ( ! -d $istepListDir )
+ )
+{
+ print STDOUT "dir $istepListDir doesn't exist.\n";
+ exit ERR_NO_ISTEP_LIST_DIR;
+}
+
+## extract tag block
+if ( extractTagBlock( $opt_tag_file ) != 0 )
+{
+ print STDOUT "No Tag block in $opt_tag_file.\n";
+ exit ERR_NO_TAG_BLOCK;
+}
+
+## strip comment junk from Tag Block
+$Tag_Block =~ s/^(\*|\s)*//gmo;
+
+## split cleaned up lines from Tag_block into an array
+my @tag_lines = split /^/, $Tag_Block;
+
+## print STDERR "@tag_lines";
+
+## check to make sure this is the correct tag file
+if ( $opt_debug ) { print "--$tag_lines[0]\n"; }
+if ( ( !defined $tag_lines[0] )
+ || ( ! ($tag_lines[0] =~ m/^(\*|\s)*\@.*tag\s+isteplist/) )
+ )
+{
+ print STDOUT "ERROR: The first line of the tag block MUST be \"\@tag isteplist\"\n";
+ exit ERR_INVALID_START_TAG;
+}
+
+## OK, start storing tag values
+while ( $_ = shift( @tag_lines ) )
+{
+ if ( ! defined $_ )
+ {
+ if ( $opt_debug ) { print STDERR "Done.\n"; }
+ last;
+ }
+
+ ## strip junk at the beginning
+ s/^(\*|\s)*//;
+
+ chomp;
+ if ( $opt_debug ) { print "-$_\n"; }
+
+ if ( m/\@\{/ )
+ {
+ ## process the tag block
+ processBlock( \@tag_lines );
+ }
+
+ if ( m/\@docversion/ )
+ {
+ s/^\@docversion\s+//;
+ storeTagInHash( "docversion", $_ );
+ }
+
+ if ( m/\@istepname/ )
+ {
+ s/^\@istepname\s+//;
+ storeTagInHash( "istepname", $_ );
+ }
+
+ if ( m/\@istepnum/ )
+ {
+ s/^\@istepnum\s+//;
+ storeTagInHash( "istepnum", $_ );
+ }
+
+ if ( m/\@istepdesc/ )
+ {
+ s/^\@istepdesc\s+//;
+ storeTagInHash( "istepdesc", $_ );
+ }
+}
+
+## ----- Begin writing the files. ---------------------------------
+
+# Make up (or modify) src/usr/hwpf/hwp/<@istepname>/<@istepname.H>
+# (use src/usr/hwpf/hwp/template.H as a template)
+createIstepHFile( );
+
+# Make up a new file src/usr/hwpf/hwp/<@istepname>/<@istepname.C>
+# (use src/usr/hwpf/hwp/template.C as a template)
+createIstepCFile( );
+
+createIstepListFile( );
+
+print STDOUT "Done.\n";
+
+#==============================================================================
+# SUBROUTINES
+#==============================================================================
+
+##
+## Print the usage (help) message
+##
+sub printUsage()
+{
+ print STDOUT "genIStep.pl\n";
+ print STDOUT " --tag-file <path> ( required: file containing tag block )\n";
+ print STDOUT " --istep-dir <path> ( required: directory where istep code will be generated )\n";
+
+ print STDOUT " [ --istep-list-dir <path> ] ( directory where istepNlist.H will be generated\n";
+ print STDOUT " ( this is usually src/include/usr/isteps )\n";
+ print STDOUT " [ --help ] ( prints usage message )\n";
+ ## print STDOUT " [ --dry-run ] ( prints all steps without doing anything )\n";
+}
+
+
+##
+## extract tag block from the passed-in file and put in the global $Tag_Block
+##
+sub extractTagBlock( $ )
+{
+ my ( $in_tag_file ) = @_;
+ my $data = "";
+
+ open( TAGFH, "< $in_tag_file") or die " $? : can't open $in_tag_file : $!";
+ read( TAGFH, $data, -s TAGFH ) or die "Error reading $in_tag_file: $!";
+ close TAGFH;
+
+ # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+ # Capture everything from opening '/* @tag isteplist' to end of tags '*/'
+ #
+ # Example:
+ # /*@
+ # * @tag isteplist
+ # * ...
+ # */
+ # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
+ ## Extract Tag block
+ while ($data =~ /\/\*\@((.|\n)+?)\*\//mgo )
+ {
+ $Tag_Block = $1;
+ }
+
+ if ( $Tag_Block eq "" )
+ {
+ return 1;
+ }
+
+
+
+ if ( $opt_debug )
+ {
+ print STDERR "debug: Extracted Tag Block: \n$Tag_Block\n";
+ }
+
+ return 0;
+}
+
+##
+## Store a tag in the hash table, given a key and value
+## @param $key - key
+## @param $value - value
+##
+sub storeTagInHash( $$ )
+{
+ my ( $key, $value ) = @_;
+ my $rc = 0;
+
+ if ( exists $Hash{ $key } )
+ {
+ print STDOUT "ERROR: duplicate tag \"$key\" \n";
+ $rc = ERR_DUPLICATE_TAG;
+ }
+ else
+ {
+ $Hash{ $key } = $value;
+ }
+
+ if ( $opt_debug ) { print STDERR "storetag: $key = $Hash{ $key }\n"; }
+
+ return $rc;
+}
+
+
+##
+## process a tag block from the caller
+## Note that this is passed a reference to the
+## original array so that we can shift the array
+## as we use up lines.
+sub processBlock( $ )
+{
+ my (@tag_block) = @{$_[0]}; # this is actually a copy
+ my %localhash = ();
+
+ while ( $_ = shift( @{$_[0]} ) ) ##@tag_block) )
+ {
+ chomp;
+ if ( $opt_debug ) { print "process: $_\n"; }
+ if ( m/\@}/ )
+ {
+ if ( $opt_debug ) { print "$_ : done.\n"; }
+ last;
+ }
+
+ if ( m/\@substepnum/ )
+ {
+ s/^\@substepnum\s+//;
+ #storeTagInHash( \%localhash, "substepnum", $_ );
+ $localhash{'substepnum'} = $_;
+ }
+
+ if ( m/\@substepname/ )
+ {
+ s/^\@substepname\s+//;
+ #storeTagInHash( \%localhash, "substepname", $_ );
+ $localhash{'substepname'} = $_;
+ }
+
+ if ( m/\@substepdesc/ )
+ {
+ s/^\@substepdesc\s+//;
+ #storeTagInHash( \%localhash, "substepdesc", $_ );
+ $localhash{'substepdesc'} = $_;
+ }
+
+
+ if ( m/\@target_sched/ )
+ {
+ s/^\@target_sched\s+//;
+ #storeTagInHash( \%localhash, "target_sched", $_ );
+ $localhash{'target_sched'} = $_;
+ }
+ }
+
+ ## Store results in %Hash using keys like "<key>:<substepnum>"
+ ## Keep it easy and flat.
+ if ( ( exists $localhash{'substepname'} )
+ && ( exists $localhash{'substepnum' } )
+ )
+ {
+ my $num = sprintf( "%2.2d", int($localhash{'substepnum'}) );
+ $Hash{ "substepname:$num"}= $localhash{'substepname'};
+ $Hash{ "substepnum:$num"}= $localhash{'substepnum'};
+
+ if (exists $localhash{'substepdesc'} )
+ {
+ $Hash{ "substepdesc:$num"}= $localhash{'substepdesc'};
+ }
+
+ if (exists $localhash{'target_sched'} )
+ {
+ $Hash{ "target_sched:$num"}= $localhash{'target_sched'};
+ }
+ }
+ else
+ {
+ print STDOUT "Incomplete tag block for $localhash{'substepname'}\n";
+
+ }
+}
+
+##
+## Back up old file before we start modifying it, if it exists.
+##
+sub backupOldFile( $ )
+{
+ my $backupFileName = shift;
+
+ if ( $opt_debug )
+ {
+ print STDERR "backing up $backupFileName, if necessary...\n";
+ }
+
+ if ( -e $backupFileName )
+ {
+ my $ts = `date +%Y-%m-%d.%H%M`;
+ chomp $ts;
+ my $old_file = "$backupFileName.org_$ts";
+ print STDOUT " $backupFileName exists, renaming to $old_file\n";
+ rename( $backupFileName, "$old_file" );
+ }
+}
+
+##
+## Apply all the tags that belong to the istep to a multiline string
+## @docversion
+## @istepname
+## @istepnum
+## @istepdesc
+##
+## param[in,out] - ref to a multiline string
+##
+## Assumes that the istep tag values stored in the correct place in %Hash
+##
+sub applyIstepTags
+{
+ my $str_ref = shift;
+ my $istepname = $Hash{'istepname'};
+ my $istepnum = $Hash{'istepnum'};
+ my $docversion = $Hash{'docversion'};
+ my $istepdesc = $Hash{'istepdesc'};
+ my $upCaseistepname = toupper( $istepname );
+ my $timestamp = `date +%Y-%m-%d:%H%M`;
+ chomp $timestamp;
+
+ ${$str_ref} =~ s/\@timestamp/$timestamp/gmo;
+ # replace "@@istepname"
+ ${$str_ref} =~ s/\@\@istepname/$upCaseistepname/gmo;
+ # replace "@istepname"
+ ${$str_ref} =~ s/\@istepname/$istepname/gmo;
+ # replace "istepnum"
+ ${$str_ref} =~ s/\@istepnum/$istepnum/gmo;
+ # replace "@istepdesc"
+ ${$str_ref} =~ s/\@istepdesc/$istepdesc/gmo;
+ # replace "@docversion"
+ ${$str_ref} =~ s/\@docversion/$docversion/gmo;
+
+}
+
+##
+## Make up a new file src/usr/hwpf/hwp/<@istepname>/<@istepname.H>
+## (use src/usr/hwpf/hwp/template.H as a template)Create the IstepHFile( )
+## This creates a new file, it will not carry anything over from an old file
+## Instead, it will rename the old file to <file>.org_YYYY.MM.DD:HHDD
+##
+sub createIstepHFile( )
+{
+ my $istepname = $Hash{'istepname'};
+ my $istepHfile = "$istepDir/$istepname.H";
+
+ print STDOUT "Create file $istepHfile...\n";
+
+ ## @todo sanity check - $istepDir should be src/usr/hwpf/hwp/<@istepname>/
+
+ backupOldFile( $istepHfile );
+
+ open( HFH, "> $istepHfile") or die " $? : can't open $istepHfile : $!";
+
+ ## apply all the istep tags to the header
+ applyIstepTags( \$templateHFileHdr );
+
+ ## add the original tag block as comments.
+ my $cleaned_up_tag_block = $Tag_Block;
+ chomp $cleaned_up_tag_block;
+ $cleaned_up_tag_block =~ s/^/ * /gmo;
+ $templateHFileHdr =~ s/\@tag_block/$cleaned_up_tag_block/gmo;
+
+ print HFH "$templateHFileHdr\n";
+
+ ## generate substeps
+ my @substepnames = sort grep /substepname/, ( keys %Hash );
+ my @substepnums = sort grep /substepnum/, ( keys %Hash );
+ my @substepdescs = sort grep /substepdesc/, ( keys %Hash );
+ if ( $opt_debug )
+ {
+
+ print "$istepname.H file: @substepnames\n";
+ print STDERR "substeps last index = $#substepnames.\n";
+ }
+
+ ## write each substep section
+ for ( my $i=0; $i<=$#substepnames; $i++ )
+ {
+ ## make a local copy to modify
+ my $templateHSS = $templateHFileSubStep;
+ applyIstepTags( \$templateHSS );
+
+ # replace "@substepname"
+ $templateHSS =~ s/\@substepname/$Hash{$substepnames[$i]}/gmo;
+ # replace "substepnum"
+ $templateHSS =~ s/\@substepnum/$Hash{$substepnums[$i]}/gmo;
+ # replace "@substepdesc"
+ $templateHSS =~ s/\@substepdesc/$Hash{$substepdescs[$i]}/gmo;
+
+ print HFH "\n$templateHSS\n";
+ }
+
+ print HFH "$templateHFileTrailer\n";
+
+
+ close HFH;
+}
+
+
+##
+## Make up a new file src/usr/hwpf/hwp/<@istepname>/<@istepname.C>
+## (use src/usr/hwpf/hwp/template.C as a template)
+## This creates a new file, it will not carry anything over from an old file
+## Instead, it will rename the old file to <file>.org_YYYY.MM.DD:HHDD
+##
+sub createIstepCFile( )
+{
+ my $istepname = $Hash{'istepname'};
+ my $istepCfile = "$istepDir/$istepname.C";
+
+ print STDOUT "Create file $istepCfile...\n";
+
+ ## sanity check - $istepDir should be src/usr/hwpf/hwp/<@istepname>/
+
+ backupOldFile( $istepCfile );
+
+ open( CFH, "> $istepCfile") or die " $? : can't open $istepCfile : $!";
+
+ applyIstepTags( \$templateCFileHdr );
+ print CFH "$templateCFileHdr";
+
+ ## generate substeps
+ my @substepnames = sort grep /substepname/, ( keys %Hash );
+ my @substepnums = sort grep /substepnum/, ( keys %Hash );
+ my @substepdescs = sort grep /substepdesc/, ( keys %Hash );
+ if ( $opt_debug )
+ {
+
+ print "$istepname.C file: @substepnames\n";
+ print STDERR "substeps last index = $#substepnames\n";
+ }
+
+ ## Write the lines to include the hwp h file
+ for ( my $i=0; $i<=$#substepnames; $i++ )
+ {
+ ## Write the line to include the hwp h file
+ print CFH "// #include \"$Hash{$substepnames[$i]}/$Hash{$substepnames[$i]}.H\"\n";
+ }
+
+ applyIstepTags( \$templateCFileNSHdr );
+ print CFH "$templateCFileNSHdr\n";
+
+ ## write each substep section
+ for ( my $i=0; $i<=$#substepnames; $i++ )
+ {
+ ## make a local copy to modify
+ my $templateCSS = $templateCFileSubStep;
+ applyIstepTags( \$templateCSS );
+
+ # replace "@substepname"
+ $templateCSS =~ s/\@substepname/$Hash{$substepnames[$i]}/gmo;
+ # replace "substepnum"
+ $templateCSS =~ s/\@substepnum/$Hash{$substepnums[$i]}/gmo;
+ # replace "@substepdesc"
+ $templateCSS =~ s/\@substepdesc/$Hash{$substepdescs[$i]}/gmo;
+
+ print CFH "\n$templateCSS\n";
+ }
+
+ print CFH "$templateCFileTrailer";
+
+ close( CFH );
+}
+
+##
+## 3. [ ] Make a new istep<@istepnum>list.H file in /usr/include/isteps/
+## Add the new istep<@istepnum>list.H file to
+## src/include/usr/istepmasterlist.H in the correct place in the
+## master istep list.
+##
+sub createIstepListFile( )
+{
+
+ my $istepname = $Hash{'istepname'};
+ my $istepnum = $Hash{'istepnum'};
+ my $istepLfile = $istepListDir . "/istep" . $istepnum . "list.H";
+
+ print STDOUT "Create file $istepLfile...\n";
+
+ ## sanity check - $istepListDir should be src/include/usr/isteps
+
+ backupOldFile( $istepLfile );
+
+ open( LFH, "> $istepLfile") or die " $? : can't open $istepLfile : $!";
+
+ applyIstepTags( \$templateListFileHdr1 );
+ print LFH "$templateListFileHdr1";
+
+ ## generate substeps
+ my @substepnames = sort grep /substepname/, ( keys %Hash );
+ my @substepnums = sort grep /substepnum/, ( keys %Hash );
+ my @substepdescs = sort grep /substepdesc/, ( keys %Hash );
+ if ( $opt_debug )
+ {
+
+ print "$istepname.C file: @substepnames\n";
+ print STDERR "substeps last index = $#substepnames\n";
+ }
+
+ ## write the documentation lines in the istepNlist file
+ for ( my $i=0; $i<=$#substepnames; $i++ )
+ {
+ print LFH " * $istepnum.$Hash{$substepnums[$i]}\t $Hash{$substepnames[$i]}\n";
+ print LFH " * \t$Hash{$substepdescs[$i]}\n";
+ }
+
+ applyIstepTags( \$templateListFileHdr2 );
+ print LFH "$templateListFileHdr2";
+
+
+ ## write each substep section
+ for ( my $i=0; $i<=$#substepnames; $i++ )
+ {
+ ## make a local copy to modify
+ my $templateLSS = $templateListFileSS;
+ applyIstepTags( \$templateLSS );
+
+ # replace "@substepname"
+ $templateLSS =~ s/\@substepname/$Hash{$substepnames[$i]}/gmo;
+ # replace "substepnum"
+ $templateLSS =~ s/\@substepnum/$Hash{$substepnums[$i]}/gmo;
+ # replace "@substepdesc"
+ $templateLSS =~ s/\@substepdesc/$Hash{$substepdescs[$i]}/gmo;
+
+ ## @todo - the substep indices have to start with 0, but of course
+ ## the substeps start at 1. We have to compensate for this
+ ## with a special tag...
+ ## This needs to be fixed by modifying lookupTask, etc., in the
+ ## istepDispatcher
+ # replace "@-substepnum"
+ my $hackedSSnum = $Hash{$substepnums[$i]} - 1;
+ $templateLSS =~ s/\@-substepnum/$hackedSSnum/gmo;
+
+ print LFH "\n$templateLSS\n";
+ }
+
+ applyIstepTags( \$templateListFileTrailer );
+ print LFH "$templateListFileTrailer";
+
+
+ close LFH;
+}
+
+
+__END__
diff --git a/src/include/usr/hbotcompid.H b/src/include/usr/hbotcompid.H
index 6ff09dd16..0c36827a3 100644
--- a/src/include/usr/hbotcompid.H
+++ b/src/include/usr/hbotcompid.H
@@ -179,11 +179,12 @@ const compId_t SPD_COMP_ID = 0x1000;
const char SPD_COMP_NAME[] = "spd";
//@}
+
/** @name RESERVED
* Reserved component ID. x3100 is the component ID
- * of FipS ERRL component. Due to our use of
+ * of FipS ERRL component. Due to our use of
* of the FipS errl tool, let no Hostboot component
- * use this component ID.
+ * use this component ID.
*/
//@{
const compId_t RESERVED_COMP_ID = 0x3100;
diff --git a/src/include/usr/initservice/initsvcreasoncodes.H b/src/include/usr/initservice/initsvcreasoncodes.H
index c22e59ffe..2fe48948d 100644
--- a/src/include/usr/initservice/initsvcreasoncodes.H
+++ b/src/include/usr/initservice/initsvcreasoncodes.H
@@ -79,10 +79,12 @@ enum InitServiceModuleID
INITSVC_DO_SHUTDOWN_MOD_ID = 0x26,
//
- // ISTEP module id's
+ // ISTEP module id's.
+ // ISTEP_ERRL_ID is a generic Error ID for all the HWP's launched
+ // by an istep.
//
- HWAS_ERRL_ID = 0x30,
- DMI_TRAINING_ERRL_ID,
+ HWAS_ERRL_ID = 0x30,
+ ISTEP_ERRL_ID = 0x31,
// reserve some tasks for my unit tests...
START_CXXTEST_ERRL_ID = 0xf0,
diff --git a/src/include/usr/initservice/isteps_trace.H b/src/include/usr/initservice/isteps_trace.H
new file mode 100644
index 000000000..7613cb53b
--- /dev/null
+++ b/src/include/usr/initservice/isteps_trace.H
@@ -0,0 +1,46 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/include/usr/initservice/isteps_trace.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+#ifndef __INITSERVICE_ISTEPS_TRACE_H
+#define __INITSERVICE_ISTEPS_TRACE_H
+
+/**
+ * @file isteps_trace.H
+ *
+ * Include the Isteps trace buffer pointer for all isteps
+ * This is initialized in istepdispatcher.C
+ *
+ */
+
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <trace/interface.H>
+
+namespace ISTEPS_TRACE
+{
+
+extern trace_desc_t *g_trac_isteps_trace;
+
+} // end namespace
+
+#endif
diff --git a/src/include/usr/isteps/istep4list.H b/src/include/usr/isteps/istep04list.H
index 1250ed25c..b106a71db 100644
--- a/src/include/usr/isteps/istep4list.H
+++ b/src/include/usr/isteps/istep04list.H
@@ -59,7 +59,7 @@ namespace INITSERVICE
* 7. Apply GARD data (call GARD module)
*
*/
-const TaskInfo g_istep4[] = {
+const TaskInfo g_istep04[] = {
{
ISTEPNAME(4,0,"init_target_states"), // substep name
@@ -67,7 +67,7 @@ const TaskInfo g_istep4[] = {
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
},
{
@@ -76,7 +76,7 @@ const TaskInfo g_istep4[] = {
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
},
{
@@ -85,7 +85,7 @@ const TaskInfo g_istep4[] = {
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
},
{
@@ -94,7 +94,7 @@ const TaskInfo g_istep4[] = {
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
},
{
@@ -103,7 +103,7 @@ const TaskInfo g_istep4[] = {
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
},
{
@@ -112,35 +112,38 @@ const TaskInfo g_istep4[] = {
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
},
{
- ISTEPNAME(4, 6, "apply_gard"), // substep name
+ ISTEPNAME(4, 6, "apply_gard"), // substep name
HWAS::apply_gard, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
},
+#if 0
+ // NOT USED ANYMORE
{
- ISTEPNAME(4,7,"testHWP"), // substep name
+ ISTEP#NOTUSED#NAME(4,7,"testHWP"), // substep name
HWAS::testHWP, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- HWAS_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // error id for istep
}
}
+#endif
// END OF LIST!
};
// make a struct from the above with the number of items included
-const ExtTaskInfo g_istep4TaskList = {
- &(g_istep4[0]),
- ( sizeof(g_istep4)/sizeof(TaskInfo) ),
+const ExtTaskInfo g_istep04TaskList = {
+ &(g_istep04[0]),
+ ( sizeof(g_istep04)/sizeof(TaskInfo) ),
NULL
};
diff --git a/src/include/usr/isteps/istep10list.H b/src/include/usr/isteps/istep10list.H
new file mode 100644
index 000000000..d7c148a49
--- /dev/null
+++ b/src/include/usr/isteps/istep10list.H
@@ -0,0 +1,165 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/include/usr/isteps/istep10list.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+#ifndef __ISTEPS_ISTEP10LIST_H
+#define __ISTEPS_ISTEP10LIST_H
+
+
+/**
+ * @file istep10list.H
+ *
+ * Step 10 Hostboot SBE Centaur Init
+ * IPL FLow Doc v0.99 (02/10/12)
+ *
+ * Please see the note in initsvcstructs.H for description of
+ * the ISTEPNAME macro.
+ *
+ */
+
+
+
+#include <initservice/initsvcstructs.H>
+#include <initservice/initsvcreasoncodes.H>
+
+// include prototypes file
+#include "../../../usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.H"
+
+namespace INITSERVICE
+{
+
+const TaskInfo g_istep10[] = {
+
+ {
+ ISTEPNAME(10,00,"cen_sbe_tp_chiplet_init1"),
+ SBE_CENTAUR_INIT::call_cen_sbe_tp_chiplet_init1,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+ {
+ ISTEPNAME( 10, 01, "cen_sbe_tp_arrayinit"),
+ SBE_CENTAUR_INIT::call_cen_sbe_tp_arrayinit,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+ {
+ ISTEPNAME(10,02,"cen_sbe_tp_chiplet_init2"),
+ SBE_CENTAUR_INIT::call_cen_sbe_tp_chiplet_init2,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,03,"cen_sbe_tp_chiplet_init3"),
+ SBE_CENTAUR_INIT::call_cen_sbe_tp_chiplet_init3,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,04,"cen_sbe_chiplet_init"),
+ SBE_CENTAUR_INIT::call_cen_sbe_chiplet_init,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,05,"cen_sbe_arrayinit"),
+ SBE_CENTAUR_INIT::call_cen_sbe_arrayinit,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,06,"cen_sbe_pll_initf"),
+ SBE_CENTAUR_INIT::call_cen_sbe_pll_initf,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,07,"cen_sbe_dts_init"),
+ SBE_CENTAUR_INIT::call_cen_sbe_dts_init,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,08,"cen_sbe_initf"),
+ SBE_CENTAUR_INIT::call_cen_sbe_initf,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,09,"cen_sbe_do_manual_inits"),
+ SBE_CENTAUR_INIT::call_cen_sbe_do_manual_inits,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,10,"cen_sbe_startclocks"),
+ SBE_CENTAUR_INIT::call_cen_sbe_startclocks,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ }, {
+ ISTEPNAME(10,11,"cen_sbe_scominits"),
+ SBE_CENTAUR_INIT::call_cen_sbe_scominits,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ // END OF LIST!
+};
+
+// make a struct from the above with the number of items included
+const ExtTaskInfo g_istep10TaskList = {
+ &(g_istep10[0]),
+ ( sizeof(g_istep10)/sizeof(TaskInfo) ),
+ NULL
+};
+
+}; // end namespace
+
+#endif
diff --git a/src/include/usr/isteps/istep11list.H b/src/include/usr/isteps/istep11list.H
index 558eec37e..efb07202a 100644
--- a/src/include/usr/isteps/istep11list.H
+++ b/src/include/usr/isteps/istep11list.H
@@ -24,17 +24,25 @@
#define __ISTEPS_ISTEP11LIST_H
/**
- * * list of functions called for DMI Training - ISTEP 11 according to Dean's
- * * HostBoot IPL Flow v982
- * *
- * * 11.1. dmi_scominit : Scom setup on centaur
- * * 11.2. dmi_erepair : Restore EDI Bus eRepair data
- * * 11.3. dmi_io_dccal : Calibrate DMI interfaces
- * * 11.4. dmi_io_run_training : Run training on MC buses
- * * 11.5. host_startPRD_dmi : Load PRD for DMI domain
- * * 11.6. host_attnlisten_cen : Start listening for attentions
- * * 11.7. proc_cen_framelock : Initialize EDI Frame
- * * 11.8. cen_set_inband_addr : Set the Inband base addresses
+ * list of functions called for DMI Training - ISTEP 11 according to Dean's
+ * HostBoot IPL Flow v982
+ *
+ * 11.1. dmi_scominit
+ * : Scom setup on centaur
+ * 11.2. dmi_erepair
+ * : Restore EDI Bus eRepair data
+ * 11.3. dmi_io_dccal
+ * : Calibrate DMI interfaces
+ * 11.4. dmi_io_run_training
+ * : Run training on MC buses
+ * 11.5. host_startPRD_dmi
+ * : Load PRD for DMI domain
+ * 11.6. host_attnlisten_cen
+ * : Start listening for attentions
+ * 11.7. proc_cen_framelock
+ * : Initialize EDI Frame
+ * 11.8. cen_set_inband_addr
+ * : Set the Inband base addresses
*/
/**
@@ -59,77 +67,77 @@ namespace INITSERVICE
const TaskInfo g_istep11[] = {
{
- ISTEPNAME(11,0,"dmi_scominit"), // substep name
+ ISTEPNAME(11,00,"dmi_scominit"), // substep name
DMI_TRAINING::call_dmi_scominit, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
{
- ISTEPNAME(11,1,"dmi_erepair"), // substep name
+ ISTEPNAME(11,01,"dmi_erepair"), // substep name
DMI_TRAINING::call_dmi_erepair, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
{
- ISTEPNAME(11,2,"dmi_io_dccal"), // substep name
+ ISTEPNAME(11,02,"dmi_io_dccal"), // substep name
DMI_TRAINING::call_dmi_io_dccal, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
{
- ISTEPNAME(11,3,"dmi_io_run_training"), // substep name
+ ISTEPNAME(11,03,"dmi_io_run_training"), // substep name
DMI_TRAINING::call_dmi_io_run_training, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
{
- ISTEPNAME(11,4,"host_startPRD_dmi"), // substep name
+ ISTEPNAME(11,04,"host_startPRD_dmi"), // substep name
DMI_TRAINING::call_host_startPRD_dmi, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
{
- ISTEPNAME(11,5,"host_attnlisten_cen"), // substep name
+ ISTEPNAME(11,05,"host_attnlisten_cen"), // substep name
DMI_TRAINING::call_host_attnlisten_cen, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
{
- ISTEPNAME(11,6,"proc_cen_framelock"), // substep name
+ ISTEPNAME(11,06,"proc_cen_framelock"), // substep name
DMI_TRAINING::call_proc_cen_framelock, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
{
- ISTEPNAME(11,7,"cen_set_inband_addr"), // substep name
+ ISTEPNAME(11,07,"cen_set_inband_addr"), // substep name
DMI_TRAINING::call_cen_set_inband_addr, // pointer to fn
{
START_FN, // task type
EXT_IMAGE, // Extended Module
- DMI_TRAINING_ERRL_ID, // module id
+ ISTEP_ERRL_ID, // module id
}
},
diff --git a/src/include/usr/isteps/istep12list.H b/src/include/usr/isteps/istep12list.H
new file mode 100644
index 000000000..9f2fa6235
--- /dev/null
+++ b/src/include/usr/isteps/istep12list.H
@@ -0,0 +1,112 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/include/usr/isteps/istep12list.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+#ifndef __ISTEPS_ISTEP12LIST_H
+#define __ISTEPS_ISTEP12LIST_H
+
+
+/**
+ * @file istep12list.H
+ *
+ * IStep 12 Step 12 MC Init
+ * IPL FLow Doc v0.99 (02/10/12)
+ *
+ * 12.1 host_collect_dimm_spd :
+ * : Collect Master dimm SPD
+ * 12.2 mss_volt :
+ * : Calc dimm voltage
+ * 12.3 mss_freq :
+ * : Calc dimm frequency
+ * 12.4 mss_eff_config :
+ * : Determine effective config
+ *
+ * Please see the note in initsvcstructs.H for description of
+ * the ISTEPNAME macro.
+ *
+ */
+
+
+
+#include <initservice/initsvcstructs.H>
+#include <initservice/initsvcreasoncodes.H>
+
+// include prototypes file
+#include "../../../usr/hwpf/hwp/mc_init/mc_init.H"
+
+
+
+namespace INITSERVICE
+{
+
+const TaskInfo g_istep12[] = {
+
+ {
+ ISTEPNAME( 12,00,"host_collect_dimm_spd"),
+ MC_INIT::call_host_collect_dimm_spd,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+ {
+ ISTEPNAME( 12,01,"mss_volt"),
+ MC_INIT::call_mss_volt,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+ {
+ ISTEPNAME( 12, 02,"mss_freq"),
+ MC_INIT::call_mss_freq,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+ {
+ ISTEPNAME( 12, 03, "mss_eff_config"),
+ MC_INIT::call_mss_eff_config,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+ // END OF LIST!
+};
+
+// make a struct from the above with the number of items included
+const ExtTaskInfo g_istep12TaskList = {
+ &(g_istep12[0]),
+ ( sizeof(g_istep12)/sizeof(TaskInfo) ),
+ NULL // later, depModules struct
+};
+
+}; // end namespace
+
+#endif
diff --git a/src/include/usr/isteps/istep13list.H b/src/include/usr/isteps/istep13list.H
new file mode 100644
index 000000000..b501c6dde
--- /dev/null
+++ b/src/include/usr/isteps/istep13list.H
@@ -0,0 +1,209 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/include/usr/isteps/istep13list.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+#ifndef __ISTEPS_ISTEP13LIST_H
+#define __ISTEPS_ISTEP13LIST_H
+
+/**
+ * @file istep13list.H
+ *
+ * IStep 13 Step 13 DRAM Training
+ * IPL FLow Doc v0.99 (02/10/12)
+ *
+ * 13.1 host_disable_vddr
+ * : Disable VDDR on CanContinue loops
+ * 13.2 mc_pll_setup
+ * : Setup PLL for MBAs
+ * 13.3 mba_startclocks
+ * : Start clocks on MBAs
+ * 13.4 host_enable_vddr
+ * : Enable the VDDR3 Voltage Rail
+ * 13.5 mss_initf
+ * : Perform scom inits to MC and PHY
+ * 13.6 mss_ddr_phy_reset
+ * : Soft reset of DDR PHY macros
+ * 13.7 mss_draminit
+ * : Dram initialize
+ * 13.8 mss_restore_dram_repair
+ * : Restore Dram repairs
+ * 13.9 mss_draminit_training
+ * : Dram training
+ * 13.10 mss_draminit_trainadv
+ * : Advanced dram training
+ * 13.11 mss_draminit_mc
+ * : Hand off control to MC
+ *
+ * *****************************************************************
+ * THIS FILE WAS GENERATED ON 2012-02-27:2142
+ * *****************************************************************
+ *
+ * Please see the note in initsvcstructs.H for description of
+ * the ISTEPNAME macro.
+ *
+ */
+
+#include <initservice/initsvcstructs.H>
+#include <initservice/initsvcreasoncodes.H>
+
+// include prototypes file
+#include "../../../usr/hwpf/hwp/dram_training/dram_training.H"
+
+namespace INITSERVICE
+{
+ const TaskInfo g_istep13[] = {
+ // NOTE: IStep indexes start with 0
+
+ {
+ ISTEPNAME(13,0,"host_disable_vddr"),
+ DRAM_TRAINING::call_host_disable_vddr,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,1,"mc_pll_setup"),
+ DRAM_TRAINING::call_mc_pll_setup,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,2,"mba_startclocks"),
+ DRAM_TRAINING::call_mba_startclocks,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,3,"host_enable_vddr"),
+ DRAM_TRAINING::call_host_enable_vddr,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,4,"mss_initf"),
+ DRAM_TRAINING::call_mss_initf,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,5,"mss_ddr_phy_reset"),
+ DRAM_TRAINING::call_mss_ddr_phy_reset,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,6,"mss_draminit"),
+ DRAM_TRAINING::call_mss_draminit,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,7,"mss_restore_dram_repair"),
+ DRAM_TRAINING::call_mss_restore_dram_repair,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,8,"mss_draminit_training"),
+ DRAM_TRAINING::call_mss_draminit_training,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,9,"mss_draminit_trainadv"),
+ DRAM_TRAINING::call_mss_draminit_trainadv,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ {
+ ISTEPNAME(13,10,"mss_draminit_mc"),
+ DRAM_TRAINING::call_mss_draminit_mc,
+ {
+ START_FN,
+ EXT_IMAGE,
+ ISTEP_ERRL_ID,
+ }
+ },
+
+
+ // END OF LIST!
+};
+
+// make a struct from the above with the number of items included
+const ExtTaskInfo g_istep13TaskList = {
+ &(g_istep13[0]),
+ ( sizeof(g_istep13)/sizeof(TaskInfo) ),
+ NULL // later, depModules struct
+};
+
+}; // end namespace
+
+#endif
diff --git a/src/include/usr/isteps/istep_template_list.H b/src/include/usr/isteps/istep_template_list.H
deleted file mode 100644
index d64510236..000000000
--- a/src/include/usr/isteps/istep_template_list.H
+++ /dev/null
@@ -1,77 +0,0 @@
-// IBM_PROLOG_BEGIN_TAG
-// This is an automatically generated prolog.
-//
-// $Source: src/include/usr/isteps/istep_template_list.H $
-//
-// IBM CONFIDENTIAL
-//
-// COPYRIGHT International Business Machines Corp. 2012
-//
-// p1
-//
-// Object Code Only (OCO) source materials
-// Licensed Internal Code Source Materials
-// IBM HostBoot Licensed Internal Code
-//
-// The source code for this program is not published or other-
-// wise divested of its trade secrets, irrespective of what has
-// been deposited with the U.S. Copyright Office.
-//
-// Origin: 30
-//
-// IBM_PROLOG_END
-//
-#ifndef __ISTEPS_ISTEP<@istepnum>LIST_H
-#define __ISTEPS_ISTEP<@istepnum>LIST_H
-
-
-/**
- * @file istep18list.H
- *
- * <@istepdesc>
- * <@docversion>
- *
- * <@istepnum>.<@substepnum> <@substepname> :
- * <@substepdesc>
- * ...
- *
- * Please see the note in initsvcstructs.H for description of
- * the ISTEPNAME macro.
- *
- */
-
-
-
-#include <initservice/initsvcstructs.H>
-#include <initservice/initsvcreasoncodes.H>
-
-// include prototypes file
-#include "../../../usr/HWPs/<@istepname>/<@istepname>.H"
-
-namespace INITSERVICE
-{
-
-const TaskInfo g_istep<@istepnum>[] = {
-
- {
- ISTEPNAME(<@istepnum>,<@substepnum>,"<@substepname>"),
- <@istepname>::call_<@substepname>,
- {
- START_FN,
- EXT_IMAGE,
- <@istepname>_ERRL_ID,
- }
- },
-
- // END OF LIST!
-};
-
-// make a struct from the above with the number of items included
-const ExtTaskInfo g_istep<@istepnum>TaskList = {
- g_istep<@istepnum>,
- ( sizeof(g_istep<@istepnum>)/sizeof(TaskInfo) )
-};
-
-}; // end namespace
-
-#endif
diff --git a/src/include/usr/isteps/istepmasterlist.H b/src/include/usr/isteps/istepmasterlist.H
index 0bb4384ea..685c77209 100644
--- a/src/include/usr/isteps/istepmasterlist.H
+++ b/src/include/usr/isteps/istepmasterlist.H
@@ -56,8 +56,12 @@
#include <initservice/initsvcstructs.H>
// ----- istep include files -----
-#include "istep4list.H"
+#include "istep04list.H"
+
+#include "istep10list.H"
#include "istep11list.H"
+#include "istep12list.H"
+#include "istep13list.H"
namespace INITSERVICE
@@ -65,23 +69,23 @@ namespace INITSERVICE
// initialize an array of ExtTaskInfo
const ExtTaskInfo g_isteps[] = {
- { NULL, 0, NULL }, // dummy IStep 0
- { NULL, 0, NULL }, // dummy IStep 1
- { NULL, 0, NULL }, // dummy IStep 2
- { NULL, 0, NULL }, // dummy IStep 3
- INITSERVICE::g_istep4TaskList, // HWAS IStep 4
- { NULL, 0, NULL }, // dummy IStep 5
- { NULL, 0, NULL }, // dummy IStep 6
- { NULL, 0, NULL }, // dummy IStep 7
- { NULL, 0, NULL }, // dummy IStep 8
- { NULL, 0, NULL }, // dummy IStep 9
- { NULL, 0, NULL }, // dummy IStep 10
- INITSERVICE::g_istep11TaskList, // DMI_TRAINING
- { NULL, 0, NULL }, // dummy IStep 12
- { NULL, 0, NULL }, // dummy IStep 13
- { NULL, 0, NULL }, // dummy IStep 14
- { NULL, 0, NULL }, // dummy IStep 15
- { NULL, 0, NULL }, // dummy IStep 16
+ { NULL, 0, NULL }, // dummy IStep 0
+ { NULL, 0, NULL }, // dummy IStep 1
+ { NULL, 0, NULL }, // dummy IStep 2
+ { NULL, 0, NULL }, // dummy IStep 3
+ INITSERVICE::g_istep04TaskList, // HWAS IStep 4
+ { NULL, 0, NULL }, // dummy IStep 5
+ { NULL, 0, NULL }, // dummy IStep 6
+ { NULL, 0, NULL }, // dummy IStep 7
+ { NULL, 0, NULL }, // dummy IStep 8
+ { NULL, 0, NULL }, // dummy IStep 9
+ INITSERVICE::g_istep10TaskList, // SBE_CENTAUR_INIT
+ INITSERVICE::g_istep11TaskList, // DMI_TRAINING
+ INITSERVICE::g_istep12TaskList, // MC_INIT
+ INITSERVICE::g_istep13TaskList, // DRAM_TRAINING
+ { NULL, 0, NULL }, // dummy IStep 14
+ { NULL, 0, NULL }, // dummy IStep 15
+ { NULL, 0, NULL }, // dummy IStep 16
//
// add further istep lists at the end.
diff --git a/src/makefile b/src/makefile
index 69687ceb3..0f97b6b8e 100644
--- a/src/makefile
+++ b/src/makefile
@@ -53,7 +53,8 @@ BASE_MODULES = trace errl devicefw scom xscom initservice taskargs \
EXTENDED_MODULES = targeting ecmddatabuffer fapi hwp plat \
extinitsvc istepdisp hwas fsi fsiscom i2c intr \
- spd dmi_training fapiporeve poreve util
+ spd dmi_training fapiporeve poreve util \
+ sbe_centaur_init mc_init dram_training
DIRECT_BOOT_MODULES = example
RUNTIME_MODULES =
diff --git a/src/usr/hwpf/hwp/dmi_training/dmi_training.C b/src/usr/hwpf/hwp/dmi_training/dmi_training.C
index 4808f2521..3123abe7d 100644
--- a/src/usr/hwpf/hwp/dmi_training/dmi_training.C
+++ b/src/usr/hwpf/hwp/dmi_training/dmi_training.C
@@ -22,15 +22,15 @@
// IBM_PROLOG_END
/**
- * @file dmi_training.C // @
+ * @file dmi_training.C
*
* Support file for hardware procedure:
- * DMI Training // @
+ * DMI Training
*
*/
/**
- * @note "// @" comments denote lines that should be built from the HWP
+ * @note "" comments denote lines that should be built from the HWP
* tag block. See the preliminary design in dmi_training.H
* Please save.
*/
@@ -41,11 +41,12 @@
/******************************************************************************/
#include <stdint.h>
-// #include <kernel/console.H>
#include <trace/interface.H>
#include <initservice/taskargs.H>
#include <errl/errlentry.H>
+#include <initservice/isteps_trace.H>
+
// targeting support.
#include <targeting/attributes.H>
#include <targeting/entitypath.H>
@@ -62,31 +63,29 @@
#include <fapiPlatHwpInvoker.H>
// -- prototype includes --
-#include "dmi_training.H" // @
-#include "proc_cen_framelock.H" // @
-#include "io_run_training.H" // @
+#include "dmi_training.H"
+#include "proc_cen_framelock.H"
+#include "io_run_training.H"
namespace DMI_TRAINING
{
-trace_desc_t *g_trac_dmi_training = NULL; // @
-TRAC_INIT(&g_trac_dmi_training, "DMI_TRAINING", 2048 ); // @
-using namespace fapi;
-using namespace TARGETING;
+using namespace TARGETING;
+using namespace fapi;
//
// Wrapper function to call 11.1 dmi_scominit
//
-void call_dmi_scominit( void *io_pArgs ) // @
+void call_dmi_scominit( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
- TRACDCOMP( g_trac_dmi_training, "call_dmi_scominit entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_dmi_scominit entry" );
- TRACDCOMP( g_trac_dmi_training, "dmi_scominit exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "dmi_scominit exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
@@ -97,15 +96,15 @@ void call_dmi_scominit( void *io_pArgs ) // @
//
// Wrapper function to call 11.2 : dmi_erepair
//
-void call_dmi_erepair( void *io_pArgs ) // @
+void call_dmi_erepair( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
- TRACDCOMP( g_trac_dmi_training, "call_dmi_erepair entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_dmi_erepair entry" );
- TRACDCOMP( g_trac_dmi_training, "dmi_erepair exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "dmi_erepair exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
@@ -115,15 +114,15 @@ void call_dmi_erepair( void *io_pArgs ) // @
//
// Wrapper function to call 11.3 : dmi_io_dccal
//
-void call_dmi_io_dccal( void *io_pArgs ) // @
+void call_dmi_io_dccal( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
- TRACDCOMP( g_trac_dmi_training, "call_dmi_io_dccal entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_dmi_io_dccal entry" );
- TRACDCOMP( g_trac_dmi_training, "dmi_io_dccal exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "dmi_io_dccal exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
@@ -134,7 +133,7 @@ void call_dmi_io_dccal( void *io_pArgs ) // @
//
// Wrapper function to call 11.4 : dmi_io_run_training
//
-void call_dmi_io_run_training( void *io_pArgs ) //@
+void call_dmi_io_run_training( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
@@ -142,7 +141,7 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
TARGETING::TargetService& l_targetService = targetService();
uint8_t l_cpuNum = 0;
- TRACDCOMP( g_trac_dmi_training, "dmi_io_run_training entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "dmi_io_run_training entry" );
// Use PredicateIsFunctional to filter only functional chips
TARGETING::PredicateIsFunctional l_isFunctional;
@@ -196,7 +195,6 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
// make a local copy of the MEMBUF target
const TARGETING::Target* l_mem_target = l_memTargetList[k];
- //@@@@@ Customized block for dmi_io_run_training @@@@@
// struct containing custom parameters that is fed to HWP
struct DmiIORunTrainingParms {
io_interface_t master_interface;
@@ -225,7 +223,7 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
(const_cast<TARGETING::Target*>(l_mem_target))
);
- TRACFCOMP( g_trac_dmi_training,
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
"===== Call dmi_io_run_training HWP( cpu 0x%x, mcs 0x%x, mem 0x%x ) : ",
l_cpuNum,
l_mcsNum,
@@ -238,7 +236,7 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
l_path.dump();
l_path = l_mem_target->getAttr<ATTR_PHYS_PATH>();
l_path.dump();
- TRACFCOMP( g_trac_dmi_training, "===== " );
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "===== " );
l_fapirc = io_run_training(
l_fapi_master_target,
@@ -247,12 +245,11 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
l_fapi_slave_target,
l_CustomParms[l_mcsNum].slave_interface,
l_CustomParms[l_mcsNum].slave_group );
- //@@@@@
// process return code.
if ( l_fapirc == fapi::FAPI_RC_SUCCESS )
{
- TRACFCOMP( g_trac_dmi_training,
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
"SUCCESS : io_run_training HWP( cpu 0x%x, mcs 0x%x, mem 0x%x ) ",
l_cpuNum,
l_mcsNum,
@@ -263,7 +260,7 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
/**
* @todo fapi error - just print out for now...
*/
- TRACFCOMP( g_trac_dmi_training,
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
"ERROR %d : io_run_training HWP( cpu 0x%x, mcs 0x%x, mem 0x%x ) ",
static_cast<uint32_t>(l_fapirc),
l_cpuNum,
@@ -277,7 +274,7 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
} // end for l_cpu_target
- TRACDCOMP( g_trac_dmi_training, "call_io_run_training exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_io_run_training exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
@@ -288,15 +285,15 @@ void call_dmi_io_run_training( void *io_pArgs ) //@
//
// Wrapper function to call 11.5 : host_startPRD_dmi
//
-void call_host_startPRD_dmi( void *io_pArgs ) // @
+void call_host_startPRD_dmi( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
- TRACDCOMP( g_trac_dmi_training, "call_host_startPRD_dmi entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_startPRD_dmi entry" );
- TRACDCOMP( g_trac_dmi_training, "host_startPRD_dmi exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "host_startPRD_dmi exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
@@ -307,15 +304,15 @@ void call_host_startPRD_dmi( void *io_pArgs ) // @
//
// Wrapper function to call 11.6 : host_attnlisten_cen
//
-void call_host_attnlisten_cen( void *io_pArgs ) // @
+void call_host_attnlisten_cen( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
- TRACDCOMP( g_trac_dmi_training, "call_host_attnlisten_cen entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_attnlisten_cen entry" );
- TRACDCOMP( g_trac_dmi_training, "<host_attnlisten_cen exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "<host_attnlisten_cen exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
@@ -325,7 +322,7 @@ void call_host_attnlisten_cen( void *io_pArgs ) //
//
// Wrapper function to call 11.7 : proc_cen_framelock
//
-void call_proc_cen_framelock( void *io_pArgs ) // @
+void call_proc_cen_framelock( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
@@ -338,7 +335,7 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
TARGETING::PredicateIsFunctional l_isFunctional;
- TRACDCOMP( g_trac_dmi_training, "call_proc_cen_framework entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_proc_cen_framework entry" );
TARGETING::PredicateCTM l_procChipFilter( CLASS_CHIP, TYPE_PROC );
TARGETING::PredicatePostfixExpr l_functionalAndProcChipFilter;
@@ -388,7 +385,6 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
// make a local copy of the MEMBUF target
const TARGETING::Target* l_mem_target = l_memTargetList[k];
- //@@@@@ Customized block for proc_cen_framelock @@@@@@
// fill out the args struct.
l_args.mcs_pu = l_mcsNum;
@@ -411,7 +407,7 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
(const_cast<TARGETING::Target*>(l_mem_target))
);
- TRACFCOMP( g_trac_dmi_training,
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
"===== Call proc_cen_framelock HWP( cpu 0x%x, mcs 0x%x, mem 0x%x ) : ",
l_cpuNum,
l_mcsNum,
@@ -423,7 +419,7 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
l_path.dump();
l_path = l_mem_target->getAttr<ATTR_PHYS_PATH>();
l_path.dump();
- TRACFCOMP( g_trac_dmi_training, "===== " );
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "===== " );
// finally!
l_fapirc = proc_cen_framelock(
@@ -431,10 +427,9 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
l_fapiMemTarget,
l_args );
- //@@@@@
if ( l_fapirc == fapi::FAPI_RC_SUCCESS )
{
- TRACFCOMP( g_trac_dmi_training,
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
"SUCCESS : proc_cen_framelock HWP( cpu 0x%x, mcs 0x%x, mem 0x%x ) ",
l_cpuNum,
l_mcsNum,
@@ -445,7 +440,7 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
/**
* @todo fapi error - just print out for now...
*/
- TRACFCOMP( g_trac_dmi_training,
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
"ERROR %d : proc_cen_framelock HWP( cpu 0x%x, mcs 0x%x, mem 0x%x )",
static_cast<uint32_t>(l_fapirc),
l_cpuNum,
@@ -456,8 +451,7 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
} // end mcs
} // end cpu
- //@ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
- TRACDCOMP( g_trac_dmi_training, "call_proc_cen_framework exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_proc_cen_framework exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
@@ -468,15 +462,15 @@ void call_proc_cen_framelock( void *io_pArgs ) // @
//
// Wrapper function to call 11.8 : cen_set_inband_addr
//
-void call_cen_set_inband_addr( void *io_pArgs ) // @
+void call_cen_set_inband_addr( void *io_pArgs )
{
INITSERVICE::TaskArgs *pTaskArgs =
static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
- TRACDCOMP( g_trac_dmi_training, "call_cen_set_inband_addr entry" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_set_inband_addr entry" );
- TRACDCOMP( g_trac_dmi_training, "cen_set_inband_addr exit" ); //@
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "cen_set_inband_addr exit" );
// wait here on the barrier, then end the task.
pTaskArgs->waitChildSync();
diff --git a/src/usr/hwpf/hwp/dram_training/dram_training.C b/src/usr/hwpf/hwp/dram_training/dram_training.C
new file mode 100644
index 000000000..82148913d
--- /dev/null
+++ b/src/usr/hwpf/hwp/dram_training/dram_training.C
@@ -0,0 +1,815 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/dram_training/dram_training.C $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+/**
+ * @file dram_training.C
+ *
+ * Support file for IStep: dram_training
+ * Step 13 DRAM Training
+ *
+ * *****************************************************************
+ * THIS FILE WAS GENERATED ON 2012-02-27:2142
+ * *****************************************************************
+ *
+ */
+
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+#include <trace/interface.H>
+#include <initservice/taskargs.H>
+#include <errl/errlentry.H>
+
+#include <initservice/isteps_trace.H>
+
+// targeting support
+#include <targeting/attributes.H>
+#include <targeting/entitypath.H>
+#include <targeting/target.H>
+#include <targeting/targetservice.H>
+#include <targeting/iterators/rangefilter.H>
+#include <targeting/predicates/predicatectm.H>
+#include <targeting/predicates/predicatepostfixexpr.H>
+#include <targeting/predicates/predicateisfunctional.H>
+
+// fapi support
+#include <fapi.H>
+#include <fapiPlatHwpInvoker.H>
+
+
+// -- prototype includes --
+// Add any customized routines that you don't want overwritten into
+// "dram_training_custom.C" and include the prototypes here.
+// #include "dram_training_custom.H"
+
+#include "dram_training.H"
+
+// Uncomment these files as they become available:
+// #include "host_disable_vddr/host_disable_vddr.H"
+// #include "mc_pll_setup/mc_pll_setup.H"
+// #include "mba_startclocks/mba_startclocks.H"
+// #include "host_enable_vddr/host_enable_vddr.H"
+// #include "mss_initf/mss_initf.H"
+// #include "mss_ddr_phy_reset/mss_ddr_phy_reset.H"
+// #include "mss_draminit/mss_draminit.H"
+// #include "mss_restore_dram_repair/mss_restore_dram_repair.H"
+// #include "mss_draminit_training/mss_draminit_training.H"
+// #include "mss_draminit_trainadv/mss_draminit_trainadv.H"
+// #include "mss_draminit_mc/mss_draminit_mc.H"
+
+namespace DRAM_TRAINING
+{
+
+using namespace TARGETING;
+using namespace fapi;
+
+
+
+//
+// Wrapper function to call 13.1 : host_disable_vddr
+//
+void call_host_disable_vddr( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_disable_vddr entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== host_disable_vddr HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = host_disable_vddr( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : host_disable_vddr HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: host_disable_vddr HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_disable_vddr exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.2 : mc_pll_setup
+//
+void call_mc_pll_setup( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mc_pll_setup entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mc_pll_setup HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mc_pll_setup( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mc_pll_setup HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mc_pll_setup HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mc_pll_setup exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.3 : mba_startclocks
+//
+void call_mba_startclocks( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mba_startclocks entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mba_startclocks HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mba_startclocks( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mba_startclocks HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mba_startclocks HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mba_startclocks exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.4 : host_enable_vddr
+//
+void call_host_enable_vddr( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_enable_vddr entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== host_enable_vddr HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = host_enable_vddr( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : host_enable_vddr HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: host_enable_vddr HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_enable_vddr exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.5 : mss_initf
+//
+void call_mss_initf( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_initf entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mss_initf HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mss_initf( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mss_initf HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_initf HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_initf exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.6 : mss_ddr_phy_reset
+//
+void call_mss_ddr_phy_reset( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_ddr_phy_reset entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mss_ddr_phy_reset HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mss_ddr_phy_reset( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mss_ddr_phy_reset HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_ddr_phy_reset HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_ddr_phy_reset exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.7 : mss_draminit
+//
+void call_mss_draminit( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mss_draminit HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mss_draminit( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mss_draminit HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_draminit HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.8 : mss_restore_dram_repair
+//
+void call_mss_restore_dram_repair( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_restore_dram_repair entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mss_restore_dram_repair HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mss_restore_dram_repair( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mss_restore_dram_repair HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_restore_dram_repair HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_restore_dram_repair exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.9 : mss_draminit_training
+//
+void call_mss_draminit_training( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit_training entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mss_draminit_training HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mss_draminit_training( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mss_draminit_training HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_draminit_training HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit_training exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.10 : mss_draminit_trainadv
+//
+void call_mss_draminit_trainadv( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit_trainadv entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mss_draminit_trainadv HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mss_draminit_trainadv( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mss_draminit_trainadv HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_draminit_trainadv HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit_trainadv exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+
+//
+// Wrapper function to call 13.11 : mss_draminit_mc
+//
+void call_mss_draminit_mc( void *io_pArgs )
+{
+ // @todo remove when join() merged
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit_mc entry" );
+
+#if 0
+ // @@@@@ CUSTOM BLOCK: @@@@@
+ // figure out what targets we need
+ // customize any other inputs
+ // set up loops to go through all targets (if parallel, spin off a task)
+
+ // print call to hwp and dump physical path of the target(s)
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "===== mss_draminit_mc HWP(? ? ? )",
+ ?
+ ?
+ ? );
+ // dump physical path to targets
+ EntityPath l_path;
+ l_path = l_@targetN_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( g_trac_mc_init, "===== " );
+
+ // cast OUR type of target to a FAPI type of target.
+ const fapi::Target l_fapi_@targetN_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_@targetN_target)) );
+
+ // call the HWP with each fapi::Target
+ l_fapirc = mss_draminit_mc( ? , ?, ? );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::ISTEPS_TRACE::g_trac_isteps_traces_trace,
+ "SUCCESS : mss_draminit_mc HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_draminit_mc HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ // @@@@@ END CUSTOM BLOCK: @@@@@
+#endif
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_draminit_mc exit" );
+
+ // end the task.
+ pTaskArgs->waitChildSync(); // @todo remove when join() merged
+ task_end();
+}
+
+
+}; // end namespace
diff --git a/src/usr/hwpf/hwp/dram_training/dram_training.H b/src/usr/hwpf/hwp/dram_training/dram_training.H
new file mode 100644
index 000000000..67c71fcd7
--- /dev/null
+++ b/src/usr/hwpf/hwp/dram_training/dram_training.H
@@ -0,0 +1,280 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/dram_training/dram_training.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+#ifndef __DRAM_TRAINING_DRAM_TRAINING_H
+#define __DRAM_TRAINING_DRAM_TRAINING_H
+
+/**
+ * @file dram_training.H
+ *
+ * Step 13 DRAM Training
+ *
+ * All of the following routines are "named isteps" - they are invoked as
+ * tasks by the @ref IStepDispatcher.
+ *
+ * *****************************************************************
+ * THIS FILE WAS GENERATED ON 2012-02-27:2142
+ * *****************************************************************
+ *
+ */
+
+/*@
+ * @tag isteplist
+ * @docversion v0.99 (02/10/12)
+ * @istepname dram_training
+ * @istepnum 13
+ * @istepdesc Step 13 DRAM Training
+ * @{
+ * @substepnum 1
+ * @substepname host_disable_vddr
+ * @substepdesc : Disable VDDR on CanContinue loops
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 2
+ * @substepname mc_pll_setup
+ * @substepdesc : Setup PLL for MBAs
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 3
+ * @substepname mba_startclocks
+ * @substepdesc : Start clocks on MBAs
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 4
+ * @substepname host_enable_vddr
+ * @substepdesc : Enable the VDDR3 Voltage Rail
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 5
+ * @substepname mss_initf
+ * @substepdesc : Perform scom inits to MC and PHY
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 6
+ * @substepname mss_ddr_phy_reset
+ * @substepdesc : Soft reset of DDR PHY macros
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 7
+ * @substepname mss_draminit
+ * @substepdesc : Dram initialize
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 8
+ * @substepname mss_restore_dram_repair
+ * @substepdesc : Restore Dram repairs
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 9
+ * @substepname mss_draminit_training
+ * @substepdesc : Dram training
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 10
+ * @substepname mss_draminit_trainadv
+ * @substepdesc : Advanced dram training
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 11
+ * @substepname mss_draminit_mc
+ * @substepdesc : Hand off control to MC
+ * @target_sched serial
+ * @}
+ */
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+namespace DRAM_TRAINING
+{
+
+
+
+/**
+ * @brief host_disable_vddr
+ *
+ * 13.1 : : Disable VDDR on CanContinue loops
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_host_disable_vddr( void * io_pArgs );
+
+
+
+/**
+ * @brief mc_pll_setup
+ *
+ * 13.2 : : Setup PLL for MBAs
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mc_pll_setup( void * io_pArgs );
+
+
+
+/**
+ * @brief mba_startclocks
+ *
+ * 13.3 : : Start clocks on MBAs
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mba_startclocks( void * io_pArgs );
+
+
+
+/**
+ * @brief host_enable_vddr
+ *
+ * 13.4 : : Enable the VDDR3 Voltage Rail
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_host_enable_vddr( void * io_pArgs );
+
+
+
+/**
+ * @brief mss_initf
+ *
+ * 13.5 : : Perform scom inits to MC and PHY
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_initf( void * io_pArgs );
+
+
+
+/**
+ * @brief mss_ddr_phy_reset
+ *
+ * 13.6 : : Soft reset of DDR PHY macros
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_ddr_phy_reset( void * io_pArgs );
+
+
+
+/**
+ * @brief mss_draminit
+ *
+ * 13.7 : : Dram initialize
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_draminit( void * io_pArgs );
+
+
+
+/**
+ * @brief mss_restore_dram_repair
+ *
+ * 13.8 : : Restore Dram repairs
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_restore_dram_repair( void * io_pArgs );
+
+
+
+/**
+ * @brief mss_draminit_training
+ *
+ * 13.9 : : Dram training
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_draminit_training( void * io_pArgs );
+
+
+
+/**
+ * @brief mss_draminit_trainadv
+ *
+ * 13.10 : : Advanced dram training
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_draminit_trainadv( void * io_pArgs );
+
+
+
+/**
+ * @brief mss_draminit_mc
+ *
+ * 13.11 : : Hand off control to MC
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_draminit_mc( void * io_pArgs );
+
+
+}; // end namespace
+
+#endif
+
diff --git a/src/usr/hwpf/hwp/dram_training/makefile b/src/usr/hwpf/hwp/dram_training/makefile
new file mode 100644
index 000000000..748f821ed
--- /dev/null
+++ b/src/usr/hwpf/hwp/dram_training/makefile
@@ -0,0 +1,48 @@
+# IBM_PROLOG_BEGIN_TAG
+# This is an automatically generated prolog.
+#
+# $Source: src/usr/hwpf/hwp/dram_training/makefile $
+#
+# IBM CONFIDENTIAL
+#
+# COPYRIGHT International Business Machines Corp. 2012
+#
+# p1
+#
+# Object Code Only (OCO) source materials
+# Licensed Internal Code Source Materials
+# IBM HostBoot Licensed Internal Code
+#
+# The source code for this program is not published or other-
+# wise divested of its trade secrets, irrespective of what has
+# been deposited with the U.S. Copyright Office.
+#
+# Origin: 30
+#
+# IBM_PROLOG_END
+
+ROOTPATH = ../../../../..
+
+MODULE = dram_training
+
+## support for Targeting and fapi
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/ecmddatabuffer
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/fapi
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/plat
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/hwp
+
+## pointer to common HWP files
+EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/include
+
+## Include sub dirs
+## NOTE: add a new EXTRAINCDIR when you add a new HWP
+## EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/??
+
+
+OBJS = dram_training.o
+
+
+## NOTE: add a new directory onto the vpaths when you add a new HWP
+## VPATH += ${ROOTPATH}/src/usr/hwpf/hwp/??
+
+include ${ROOTPATH}/config.mk
diff --git a/src/usr/hwpf/hwp/makefile b/src/usr/hwpf/hwp/makefile
index 59d174969..1b61ac826 100644
--- a/src/usr/hwpf/hwp/makefile
+++ b/src/usr/hwpf/hwp/makefile
@@ -39,7 +39,8 @@ OBJS = fapiTestHwp.o \
dimmBadDqBitmapFuncs.o \
dimmBadDqBitmapAccessHwp.o
-SUBDIRS = dmi_training.d
+SUBDIRS = dmi_training.d sbe_centaur_init.d mc_init.d \
+ dram_training.d
include ${ROOTPATH}/config.mk
diff --git a/src/usr/hwpf/hwp/mc_init/makefile b/src/usr/hwpf/hwp/mc_init/makefile
new file mode 100644
index 000000000..3deb94aed
--- /dev/null
+++ b/src/usr/hwpf/hwp/mc_init/makefile
@@ -0,0 +1,50 @@
+# IBM_PROLOG_BEGIN_TAG
+# This is an automatically generated prolog.
+#
+# $Source: src/usr/hwpf/hwp/mc_init/makefile $
+#
+# IBM CONFIDENTIAL
+#
+# COPYRIGHT International Business Machines Corp. 2012
+#
+# p1
+#
+# Object Code Only (OCO) source materials
+# Licensed Internal Code Source Materials
+# IBM HostBoot Licensed Internal Code
+#
+# The source code for this program is not published or other-
+# wise divested of its trade secrets, irrespective of what has
+# been deposited with the U.S. Copyright Office.
+#
+# Origin: 30
+#
+# IBM_PROLOG_END
+
+ROOTPATH = ../../../../..
+
+MODULE = mc_init
+
+## support for Targeting and fapi
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/ecmddatabuffer
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/fapi
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/plat
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/hwp
+
+## pointer to common HWP files
+EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/include
+
+## Include sub dirs
+## NOTE: add a new EXTRAINCDIR when you add a new HWP
+##@ EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/???
+EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/mc_init/mss_freq
+
+OBJS = mc_init.o \
+ mss_freq.o
+
+## NOTE: add a new directory onto the vpaths when you add a new HWP
+##@ VPATH += ${ROOTPATH}/src/usr/hwpf/hwp/???
+VPATH += ${ROOTPATH}/src/usr/hwpf/hwp/mc_init/mss_freq
+
+
+include ${ROOTPATH}/config.mk
diff --git a/src/usr/hwpf/hwp/mc_init/mc_init.C b/src/usr/hwpf/hwp/mc_init/mc_init.C
new file mode 100644
index 000000000..c623ce077
--- /dev/null
+++ b/src/usr/hwpf/hwp/mc_init/mc_init.C
@@ -0,0 +1,284 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/mc_init/mc_init.C $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+/**
+ * @file mc_init.C
+ *
+ * Support file for IStep:
+ * mc_init
+
+ */
+
+
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+// #include <kernel/console.H>
+#include <trace/interface.H>
+#include <initservice/taskargs.H>
+#include <errl/errlentry.H>
+
+#include <initservice/isteps_trace.H>
+
+// targeting support
+#include <targeting/attributes.H>
+#include <targeting/entitypath.H>
+#include <targeting/target.H>
+#include <targeting/targetservice.H>
+#include <targeting/iterators/rangefilter.H>
+#include <targeting/predicates/predicatectm.H>
+#include <targeting/predicates/predicatepostfixexpr.H>
+#include <targeting/predicates/predicateisfunctional.H>
+
+// fapi support
+#include <fapi.H>
+#include <fapiPlatHwpInvoker.H>
+
+// -- prototype includes --
+#include "mc_init.H"
+// #include "mss_volt/mss_volt.H"
+#include "mss_freq/mss_freq.H"
+
+namespace MC_INIT
+{
+
+using namespace TARGETING;
+using namespace fapi;
+
+//
+// Wrapper function to call 12.1 : mss_volt
+//
+void call_host_collect_dimm_spd( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_host_collect_dimm_spd" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== host_collect_dimm_spd(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = host_collect_dimm_spd( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : host_collect_dimm_spd(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: host_collect_dimm_spd(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "host_collect_dimm_spd" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+//
+// Wrapper function to call 12.2 : mss_volt
+//
+void call_mss_volt( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_volt entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== mss_volt HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = mss_volt( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : mss_volt HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_volt HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "mss_volt exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+//
+// Wrapper function to call 12.3 : mss_freq
+//
+void call_mss_freq( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_freq entry" );
+
+
+ // figure out what targets we need
+ // Use PredicateIsFunctional to filter only functional chips
+ TARGETING::PredicateIsFunctional l_isFunctional;
+ // filter for functional Centaur Chips
+ TARGETING::PredicateCTM l_membufChipFilter(CLASS_CHIP, TYPE_MEMBUF);
+ // declare a postfix expression widget
+ TARGETING::PredicatePostfixExpr l_functionalAndMembufChipFilter;
+ // is-a-membuf-chip is-functional AND
+ l_functionalAndMembufChipFilter.push(&l_membufChipFilter).push(&l_isFunctional).And();
+ // loop through all the targets, applying the filter, and put the results in l_pMemBufs
+ TARGETING::TargetRangeFilter l_pMemBufs(
+ TARGETING::targetService().begin(),
+ TARGETING::targetService().end(),
+ &l_functionalAndMembufChipFilter );
+
+ for ( uint8_t l_memBufNum=0 ;
+ l_pMemBufs ;
+ l_memBufNum++, ++l_pMemBufs
+ )
+ {
+ // make a local copy of the target for ease of use
+ const TARGETING::Target* l_membuf_target = *l_pMemBufs;
+
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== mss_freq HWP( %d )",
+ l_memBufNum );
+ EntityPath l_path;
+ l_path = l_membuf_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "===== " );
+
+ // call the HWP with each target ( if parallel, spin off a task )
+ // $$const fapi::Target l_fapi_membuf_target(
+ fapi::Target l_fapi_membuf_target(
+ TARGET_TYPE_MEMBUF_CHIP,
+ reinterpret_cast<void *>
+ (const_cast<TARGETING::Target*>(l_membuf_target)) );
+
+ l_fapirc = mss_freq( l_fapi_membuf_target );
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : mss_freq HWP( %d )", l_memBufNum );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_freq HWP( %d ) ",
+ static_cast<uint32_t>(l_fapirc),
+ l_memBufNum );
+ }
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_freq exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 12.4 : mss_eff_config
+//
+void call_mss_eff_config( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_eff_config" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== mss_eff_config HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = mss_eff_config( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : mss_eff_config HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: mss_eff_config HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_mss_eff_config exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+}; // end namespace
+
diff --git a/src/usr/hwpf/hwp/mc_init/mc_init.H b/src/usr/hwpf/hwp/mc_init/mc_init.H
new file mode 100644
index 000000000..6ea945a2f
--- /dev/null
+++ b/src/usr/hwpf/hwp/mc_init/mc_init.H
@@ -0,0 +1,143 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/mc_init/mc_init.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+//
+// #########################################
+// THIS WILL BE A GENERATED FILE
+// #########################################
+//
+
+/*@
+ * @tag isteplist
+ * @docversion v0.99 (02/10/12)
+ * @istepname mc_init
+ * @istepnum 12
+ * @istepdesc Step 12 MC Init
+ *
+ * @{
+ * @substepnum 1
+ * @substepname host_collect_dimm_spd
+ * @substepdesc : Collect Master dimm SPD
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 2
+ * @substepname mss_volt
+ * @substepdesc : Calc dimm voltage
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 3
+ * @substepname mss_freq
+ * @substepdesc : Calc dimm frequency
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 4
+ * @substepname mss_eff_config
+ * @substepdesc : Determine effective config
+ * @target_sched serial
+ * @}
+ *
+ */
+
+#ifndef __MC_INIT_MC_INIT_H
+#define __MC_INIT_MC_INIT_H
+/**
+ * @file mc_init.H
+ *
+ * @istepdesc
+ *
+ * All of the following routines are "named isteps" - they are invoked as
+ * tasks by the @ref IStepDispatcher.
+ *
+ */
+
+
+
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+
+namespace MC_INIT
+{
+
+/**
+ * @brief host_collect_dimm_spd
+ *
+ * 12.1 : Collect Master dimm SPD
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_host_collect_dimm_spd( void * io_pArgs );
+
+
+/**
+ * @brief mss_volt
+ *
+ * 12.2 : : Calc dimm voltage
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_volt( void * io_pArgs );
+
+
+/**
+ * @brief mss_freq
+ *
+ * 12.3 : Calc dimm frequency
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_freq( void * io_pArgs );
+
+
+/**
+ * @brief mss_eff_config
+ *
+ * 12.4 : Determine effective config
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+void call_mss_eff_config( void * io_pArgs );
+
+}; // end namespace
+
+#endif
diff --git a/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.C b/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.C
new file mode 100644
index 000000000..3d6573c9e
--- /dev/null
+++ b/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.C
@@ -0,0 +1,188 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.C $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+/* File mss_volt.C created by JEFF SABROWSKI on Fri 21 Oct 2011. */
+
+//------------------------------------------------------------------------------
+// *! (C) Copyright International Business Machines Corp. 2007
+// *! All Rights Reserved -- Property of IBM
+// *! *** IBM Confidential ***
+//------------------------------------------------------------------------------
+// *! TITLE : mss_freq.C
+// *! DESCRIPTION : Tools for centaur procedures
+// *! OWNER NAME : Jeff Sabrowski (jsabrow@us.ibm.com)
+// *! BACKUP NAME :
+// #! ADDITIONAL COMMENTS :
+//
+// General purpose funcs
+
+//------------------------------------------------------------------------------
+// Don't forget to create CVS comments when you check in your changes!
+//------------------------------------------------------------------------------
+// CHANGE HISTORY:
+//------------------------------------------------------------------------------
+// Version:| Author: | Date: | Comment:
+//---------|----------|----------|----------------------------------------------
+// 1.1 | jsabrow | 09/30/11 | Initial draft.
+// 1.2 | bellows | 12/21/11 | fixed function call to mss_freq
+// 1.4 | jsabrow |
+// This procedure takes CENTAUR as argument. for each DIMM (under each MBA)
+// DIMM SPD attributes are read to determine optimal DRAM frequency
+// frequency bins: 800*, 1066*, 1333, 1600, 1866, 2133, 2400*, 2666*
+// (*=not supported in product as of feb'12)
+
+//----------------------------------------------------------------------
+// Includes - FAPI
+//----------------------------------------------------------------------
+#include <fapi.H>
+#include <mss_freq.H>
+
+using namespace fapi;
+
+fapi::ReturnCode mss_freq(fapi::Target &i_target_memb)
+{
+ fapi::ReturnCode l_rc;
+ std::vector<fapi::Target> l_mbaChiplets;
+ std::vector<fapi::Target> l_dimm_targets;
+ uint8_t l_spd_byte10=0;
+ uint8_t l_spd_byte11=0;
+ uint8_t l_spd_byte12=0;
+ uint32_t l_spd_byte1415=0xFFFF;
+ uint8_t l_spd_byte16=0;
+ uint32_t l_dimm_freq_calc=0;
+ uint32_t l_dimm_freq_max=9999;
+ uint32_t l_selected_dimm_freq=0;
+ uint32_t l_dimm_all_cas=0;
+
+ // Get associated MBA's on this centaur
+ l_rc=fapiGetChildChiplets(i_target_memb, fapi::TARGET_TYPE_MBA_CHIPLET, l_mbaChiplets);
+ // Loop through the 2 MBA's
+ for (uint32_t i=0; i < l_mbaChiplets.size(); i++)
+ {
+ // Get a vector of DIMM targets
+ l_rc = fapiGetAssociatedDimms(l_mbaChiplets[i], l_dimm_targets);
+ for (uint32_t j=0; j < l_dimm_targets.size(); j++)
+ {
+
+ l_rc = FAPI_ATTR_GET(ATTR_SPD_MTB_DIVIDEND, &l_dimm_targets[j], l_spd_byte10);
+ if (l_rc)
+ {
+ FAPI_ERR("Unable to read SPD byte 10.");
+ break;
+ }
+
+ l_rc = FAPI_ATTR_GET(ATTR_SPD_MTB_DIVISOR, &l_dimm_targets[j], l_spd_byte11);
+ if (l_rc)
+ {
+ FAPI_ERR("Unable to read SPD byte 11.");
+ break;
+ }
+
+ l_rc = FAPI_ATTR_GET(ATTR_SPD_TCKMIN, &l_dimm_targets[j], l_spd_byte12);
+ if (l_rc)
+ {
+ FAPI_ERR("Unable to read SPD byte 12.");
+ break;
+ }
+
+ //TODO: need to check that bytes 10, 11 nor 12 are zero
+ //JEDEC doesn't allow zeroes in these bytes, but we should check.
+ //integer-safe equation for dram clock * 2
+ l_dimm_freq_calc = 2000000 / ( ( 1000 * l_spd_byte12 * l_spd_byte10 ) / l_spd_byte11);
+
+ //is this the slowest dimm?
+ if (l_dimm_freq_calc < l_dimm_freq_max)
+ {
+ l_dimm_freq_max = l_dimm_freq_calc;
+ }
+
+ l_rc = FAPI_ATTR_GET(ATTR_SPD_CAS_LATENCIES_SUPPORTED, &l_dimm_targets[j], l_spd_byte1415);
+ if (l_rc)
+ {
+ FAPI_ERR("Unable to read SPD byte 14-15.");
+ break;
+ }
+
+ //'AND' all dimm CAS support
+ l_dimm_all_cas = l_dimm_all_cas & l_spd_byte1415;
+
+ l_rc = FAPI_ATTR_GET(ATTR_SPD_TAAMIN, &l_dimm_targets[j], l_spd_byte16);
+ if (l_rc)
+ {
+ FAPI_ERR("Unable to read SPD byte 16.");
+ break;
+ }
+
+
+ }
+ }
+
+ //bucketize dimm freq.
+ if (!l_rc)
+ {
+ if (l_dimm_freq_max < 1013)
+ {
+ // 800 isn't supported
+ l_selected_dimm_freq=800;
+ }
+ else if (l_dimm_freq_max < 1266)
+ {
+ // 1066
+ l_selected_dimm_freq=1066;
+ }
+ else if (l_dimm_freq_max < 1520)
+ {
+ // 1333
+ l_selected_dimm_freq=1333;
+ }
+ else if (l_dimm_freq_max < 1773)
+ {
+ // 1600
+ l_selected_dimm_freq=1600;
+ }
+ else if (l_dimm_freq_max < 2026)
+ {
+ // 1866
+ l_selected_dimm_freq=1866;
+ }
+ else if (l_dimm_freq_max < 2280)
+ {
+ // 2133
+ l_selected_dimm_freq=2133;
+ }
+ else
+ {
+ //FAPI_ERR("Error dimm freq calculated > 2133 MHz");
+ }
+ }
+
+ //TODO: frequency consideration for CAS
+
+ // set frequency in centaur attribute ATTR_MSS_FREQ
+ if (!l_rc)
+ {
+ l_rc = FAPI_ATTR_SET(ATTR_MSS_FREQ, &i_target_memb, l_selected_dimm_freq);
+ }
+
+ //all done.
+ return l_rc;
+}
diff --git a/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.H b/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.H
new file mode 100644
index 000000000..36b67813a
--- /dev/null
+++ b/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.H
@@ -0,0 +1,68 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+//------------------------------------------------------------------------------
+// *! (C) Copyright International Business Machines Corp. 2011
+// *! All Rights Reserved -- Property of IBM
+// *! *** IBM Confidential ***
+//------------------------------------------------------------------------------
+// *! TITLE : mss_freq.H
+// *! DESCRIPTION : see additional comments below
+// *! OWNER NAME : Jeff Sabrowski Email: jsabrow@us.ibm.com
+// *! BACKUP NAME : Mark Bellows Email: bellows@us.ibm.com
+// *! ADDITIONAL COMMENTS :
+//
+// Header file for mss_freq.
+//
+//------------------------------------------------------------------------------
+// Don't forget to create CVS comments when you check in your changes!
+//------------------------------------------------------------------------------
+// CHANGE HISTORY:
+//------------------------------------------------------------------------------
+// Version:| Author: | Date: | Comment:
+//---------|----------|---------_|-----------------------------------------------
+// 1.0 | jsabrow | 11/30/11 | initial drop
+// 1.2 | jsabrow | 02/14/12 | Updates for initial code review
+
+#ifndef MSS_FREQHWPB_H_
+#define MSS_FREQHWPB_H_
+
+#include <fapi.H>
+
+typedef fapi::ReturnCode (*mss_freq_FP_t)(fapi::Target &);
+
+extern "C"
+{
+
+/**
+ * @brief mss_freq procedure. Determines operating frequency for dimms behind a centaur
+ *
+ * @param[in] fapi::Target &l_targets reference to one centaur
+ *
+ * @return ReturnCode
+ */
+
+ fapi::ReturnCode mss_freq(fapi::Target & i_target);
+
+} // extern "C"
+
+#endif // MSS_FREQHWPB_H_
diff --git a/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq_wrap.C b/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq_wrap.C
new file mode 100644
index 000000000..a689b68ef
--- /dev/null
+++ b/src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq_wrap.C
@@ -0,0 +1,138 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/mc_init/mss_freq/mss_freq_wrap.C $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+//----------------------------------------------------------------------
+// Includes
+//----------------------------------------------------------------------
+
+//----------------------------------------------------------------------
+// eCMD Includes
+//----------------------------------------------------------------------
+#include <ecmdClientCapi.H>
+#include <ecmdDataBuffer.H>
+#include <ecmdUtils.H>
+#include <ecmdSharedUtils.H>
+#include <fapiClientCapi.H>
+#include <croClientCapi.H>
+#include <fapi.H>
+
+const uint32_t BAD_ERROR_CODE = 0xFFFF0000;
+//----------------------------------------------------------------------
+
+
+int main( int argc, char *argv[] )
+{
+ uint32_t rc = ECMD_SUCCESS;
+ ecmdLooperData looperdata; // Store internal Looper data
+ ecmdLooperData looperdata2;
+ ecmdChipTarget target; // This is the chip target to operate on
+ bool validPosFound = false;
+ ecmdDataBuffer data;
+ char printStr[200];
+
+ //------------------------------------
+ // Load and initialize the eCMD Dll
+ // If left NULL, which DLL to load is determined by the ECMD_DLL_FILE environment variable
+ // If set to a specific value, the specified dll will be loaded
+ //------------------------------------
+ rc = ecmdLoadDll("");
+ if (rc) return rc;
+
+ /* This is needed if you're running a FAPI procedure via ecmdRunSo() */
+ rc = fapiInitExtension(); if (rc) { printf("Error init fapi extension\n");return rc;}
+ rc = croInitExtension(); if (rc) { printf("Error init cro extension\n");return rc;}
+
+ //------------------------------------
+ // Parse out common eCMD args like -p0, -c0, -coe, etc..
+ // Any found args will be removed from arg list upon return
+ //------------------------------------
+ rc = ecmdCommandArgs(&argc, &argv);
+ if (rc) return rc;
+
+ /* Let's always print the dll info to the screen, unless in quiet mode */
+ if (!ecmdGetGlobalVar(ECMD_GLOBALVAR_QUIETMODE)) {
+ rc = ecmdDisplayDllInfo();
+ if (rc) return rc;
+ }
+
+
+ /*******************************/
+ /* Loop over all all Centaur chips */
+ /*******************************/
+ ecmdOutput("---------------------------------------------\n");
+ ecmdOutput("Loop over all Centaur chips:\n");
+ ecmdOutput("---------------------------------------------\n");
+ target.chipType = "cen";
+ target.chipTypeState = ECMD_TARGET_FIELD_VALID;
+ target.cageState = ECMD_TARGET_FIELD_WILDCARD;
+ target.nodeState = ECMD_TARGET_FIELD_WILDCARD;
+ target.slotState = ECMD_TARGET_FIELD_WILDCARD;
+ target.posState = ECMD_TARGET_FIELD_WILDCARD;
+ target.chipUnitTypeState = ECMD_TARGET_FIELD_UNUSED;
+ target.chipUnitNumState = ECMD_TARGET_FIELD_UNUSED;
+ target.threadState = ECMD_TARGET_FIELD_UNUSED;
+
+ rc = ecmdConfigLooperInit( target, ECMD_SELECTED_TARGETS_LOOP_DEFALL, looperdata); if (rc) return rc;
+
+ std::list<uint64_t> myArgs;
+ uint64_t arg1 = 0xBB;
+ myArgs.push_back(arg1);
+ arg1 = 0xDD;
+ myArgs.push_back(arg1);
+
+ while( ecmdConfigLooperNext( target, looperdata ) ){
+ validPosFound = true;
+ snprintf(printStr, 200, "Working on ecmdChipTarget = %s\n", ecmdWriteTarget(target).c_str());
+ ecmdOutput(printStr);
+ std::string myFileWithPath;
+ std::string myFile = "mss_ddr_phy_reset_x86.so";
+ rc = fapiQueryFileLocation(FAPI_FILE_HWP, myFile, myFileWithPath); if (rc) return rc;
+ rc = fapiHwpInvoker(target, myFileWithPath, "mss_ddr_phy_reset", myArgs); if (rc) return rc;
+
+ if (rc) {
+ ecmdOutputError("-----------------------------------------------------------\n");
+ ecmdOutputError(" mss_ddr_phy_reset exited early with ...\n");
+ snprintf(printStr, 200," Return code = %s 0x%08x \n", ecmdParseReturnCode(rc).c_str(),rc);
+ ecmdOutputError(printStr);
+ ecmdOutputError("-----------------------------------------------------------\n");
+ return rc;
+ }
+ } // end of loop through all configured Centaur chips
+
+ if( rc == ECMD_SUCCESS && !validPosFound ){
+ ecmdOutputError("**** ERROR : There were no Centaur chips configured so none were initialized.");
+ rc= BAD_ERROR_CODE;
+ }
+
+ ecmdOutput("-------------------------------\n");
+ ecmdOutput(" mss_ddr_phy_reset is Done\n");
+ ecmdOutput("-------------------------------\n");
+ //------------------------------------
+ // Unload the eCMD Dll, this should always be the last thing you do
+ //------------------------------------
+ ecmdUnloadDll();
+
+ return rc;
+}
+
+
+
diff --git a/src/usr/hwpf/hwp/sbe_centaur_init/makefile b/src/usr/hwpf/hwp/sbe_centaur_init/makefile
new file mode 100644
index 000000000..457783336
--- /dev/null
+++ b/src/usr/hwpf/hwp/sbe_centaur_init/makefile
@@ -0,0 +1,47 @@
+# IBM_PROLOG_BEGIN_TAG
+# This is an automatically generated prolog.
+#
+# $Source: src/usr/hwas/makefile $
+#
+# IBM CONFIDENTIAL
+#
+# COPYRIGHT International Business Machines Corp. 2011
+#
+# p1
+#
+# Object Code Only (OCO) source materials
+# Licensed Internal Code Source Materials
+# IBM HostBoot Licensed Internal Code
+#
+# The source code for this program is not published or other-
+# wise divested of its trade secrets, irrespective of what has
+# been deposited with the U.S. Copyright Office.
+#
+# Origin: 30
+#
+# IBM_PROLOG_END
+
+ROOTPATH = ../../../../..
+
+MODULE = sbe_centaur_init
+
+## support for Targeting and fapi
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/ecmddatabuffer
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/fapi
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/plat
+EXTRAINCDIR += ${ROOTPATH}/src/include/usr/hwpf/hwp
+
+## pointer to common HWP files
+EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/include
+
+## Include sub dirs
+## NOTE: add a new EXTRAINCDIR when you add a new HWP
+## EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/sbe_centaur_init/????
+
+
+OBJS = sbe_centaur_init.o
+
+## NOTE: add a new directory onto the vpaths when you add a new HWP
+## VPATH += ${ROOTPATH}/src/usr/hwpf/hwp/sbe_centaur_init/????
+
+include ${ROOTPATH}/config.mk
diff --git a/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C b/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C
new file mode 100644
index 000000000..1dc9ad501
--- /dev/null
+++ b/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C
@@ -0,0 +1,629 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.C $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+
+/**
+ * @file sbe_centaur_init.C
+ *
+ * Support file for IStep:
+ * sbe_centaur_init
+ *
+ *
+ *
+ */
+
+
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+#include <trace/interface.H>
+#include <initservice/taskargs.H>
+#include <errl/errlentry.H>
+
+#include <initservice/isteps_trace.H>
+
+#include <targeting/targetservice.H>
+#include <targeting/iterators/rangefilter.H>
+#include <targeting/predicates/predicatectm.H>
+#include <targeting/predicates/predicatepostfixexpr.H>
+#include <targeting/predicates/predicateisfunctional.H>
+#include <fapi.H>
+
+// -- prototype includes --
+#include "sbe_centaur_init.H"
+// #include "<cen_sbe_arrayinit>/<cen_sbe_arrayinit>.H"
+
+namespace SBE_CENTAUR_INIT
+{
+
+using namespace TARGETING;
+using namespace fapi;
+
+//
+// Wrapper function to call 10.1 : cen_sbe_tp_chiplet_init1
+//
+void call_cen_sbe_tp_chiplet_init1( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_tp_chiplet_init1 entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET GENERATION STUFF HERE
+
+ // Use PredicateIsFunctional to filter only functional chips
+ TARGETING::PredicateIsFunctional l_isFunctional;
+ // filter for functional Centaur Chips
+ TARGETING::PredicateCTM l_membufChipFilter(CLASS_CHIP, TYPE_MEMBUF);
+ // declare a postfix expression widget
+ TARGETING::PredicatePostfixExpr l_functionalAndMembufChipFilter;
+ // is-a-membuf-chip is-functional AND
+ l_functionalAndMembufChipFilter.push(&l_membufChipFilter).push(&l_isFunctional).And();
+ // loop through all the targets, applying the filter, and put the results in l_pMemBufs
+ TARGETING::TargetRangeFilter l_pMemBufs(
+ TARGETING::targetService().begin(),
+ TARGETING::targetService().end(),
+ &l_functionalAndMembufChipFilter );
+
+ for ( ; l_pMemBufs; ++l_pMemBufs )
+ {
+ // make a local copy of the target for ease of use
+ const TARGETING::Target* l_membuf_target = *l_pMemBufs;
+
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_tp_chiplet_init1 HWP(? ? ? )" );
+ EntityPath l_path;
+ l_path = l_membuf_target->getAttr<ATTR_PHYS_PATH>();
+ l_path.dump();
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "===== " );
+#if 0
+ // $$$$ Thi add your code here, pass it l_membuf_target
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_tp_chiplet_init1( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc == fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_tp_chiplet_init1 HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_tp_chiplet_init1 HWP(?,?,? ) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+ } // end for l_pMemBufs
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "cen_sbe_tp_chiplet_init1 exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.2 : cen_sbe_tp_arrayinit
+//
+void call_cen_sbe_tp_arrayinit( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_tp_arrayinit entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_tp_arrayinit HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_tp_arrayinit( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_tp_arrayinit HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_tp_arrayinit HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_tp_arrayinit exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+//
+// Wrapper function to call 10.3 : cen_sbe_tp_chiplet_init2
+//
+void call_cen_sbe_tp_chiplet_init2( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_tp_chiplet_init2 entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_tp_chiplet_init2 HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_tp_chiplet_init2( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_tp_chiplet_init2 HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_tp_chiplet_init2 HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_tp_chiplet_init2 exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.4 : cen_sbe_tp_chiplet_init3
+//
+void call_cen_sbe_tp_chiplet_init3( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_tp_chiplet_init3 entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_tp_chiplet_init3 HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_tp_chiplet_init3( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_tp_chiplet_init3 HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_tp_chiplet_init3 HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_tp_chiplet_init3 exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.5 : cen_sbe_chiplet_init
+//
+void call_cen_sbe_chiplet_init( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_chiplet_init entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_chiplet_init HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_chiplet_init( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_chiplet_init HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_chiplet_init HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_chiplet_init exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.6 : cen_sbe_arrayinit
+//
+void call_cen_sbe_arrayinit( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_arrayinit entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_arrayinit HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_arrayinit( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_arrayinit HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_arrayinit HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_arrayinit exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.7 : cen_sbe_pll_initf
+//
+void call_cen_sbe_pll_initf( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_pll_initf entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_pll_initf HWP(? ? ? )" );
+
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_pll_initf( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_pll_initf HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_pll_initf HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_pll_initf exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.8 : cen_sbe_dts_init
+//
+void call_cen_sbe_dts_init( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_dts_init entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_dts_init HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_dts_init( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_dts_init HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_dts_init HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_dts_init exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.9 : cen_sbe_initf
+//
+void call_cen_sbe_initf( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_initf entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_initf HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_initf( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_initf HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_initf HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_initf exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.10 : cen_sbe_do_manual_inits
+//
+void call_cen_sbe_do_manual_inits( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_do_manual_inits entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_do_manual_inits HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_do_manual_inits( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_do_manual_inits HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_do_manual_inits HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_do_manual_inits exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.11 : cen_sbe_startclocks
+//
+void call_cen_sbe_startclocks( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_startclocks entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_startclocks HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_startclocks( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_startclocks HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_startclocks HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_startclocks exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+
+//
+// Wrapper function to call 10.12 : cen_sbe_scominits
+//
+void call_cen_sbe_scominits( void *io_pArgs )
+{
+ INITSERVICE::TaskArgs *pTaskArgs =
+ static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
+ fapi::ReturnCode l_fapirc;
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_scominits entry" );
+
+
+ // figure out what targets we need
+ // ADD TARGET CODE HERE
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "===== cen_sbe_scominits HWP(? ? ? )" );
+#if 0
+ // call the HWP with each target ( if parallel, spin off a task )
+ l_fapirc = cen_sbe_scominits( ? , ?, ? );
+#endif
+
+ // process return code.
+ if ( l_fapirc== fapi::FAPI_RC_SUCCESS )
+ {
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "SUCCESS : cen_sbe_scominits HWP(? ? ? )" );
+ }
+ else
+ {
+ /**
+ * @todo fapi error - just print out for now...
+ */
+ TRACFCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ERROR %d: cen_sbe_scominits HWP(? ? ?) ",
+ static_cast<uint32_t>(l_fapirc) );
+ }
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace, "call_cen_sbe_scominits exit" );
+
+ // wait here on the barrier, then end the task.
+ pTaskArgs->waitChildSync();
+ task_end();
+}
+
+}; // end namespace
+
diff --git a/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.H b/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.H
new file mode 100644
index 000000000..4948bdf8f
--- /dev/null
+++ b/src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.H
@@ -0,0 +1,291 @@
+// IBM_PROLOG_BEGIN_TAG
+// This is an automatically generated prolog.
+//
+// $Source: src/usr/hwpf/hwp/sbe_centaur_init/sbe_centaur_init.H $
+//
+// IBM CONFIDENTIAL
+//
+// COPYRIGHT International Business Machines Corp. 2012
+//
+// p1
+//
+// Object Code Only (OCO) source materials
+// Licensed Internal Code Source Materials
+// IBM HostBoot Licensed Internal Code
+//
+// The source code for this program is not published or other-
+// wise divested of its trade secrets, irrespective of what has
+// been deposited with the U.S. Copyright Office.
+//
+// Origin: 30
+//
+// IBM_PROLOG_END
+#ifndef __SBE_CENTAUR_INIT_SBE_CENTAUR_INIT_H
+#define __SBE_CENTAUR_INIT_SBE_CENTAUR_INIT_H
+/**
+ * @file sbe_centaur_init.H
+ *
+ * All of the following routines are "named isteps" - they are invoked as
+ * tasks by the @ref IStepDispatcher.
+ *
+ */
+
+/*@
+ * @tag isteplist
+ * @docversion v0.99 (02/10/12)
+ * @istepname sbe_centaur_init
+ * @istepnum 10
+ * @istepdesc Step 10 Hostboot SBE Centaur Init
+ *
+ * @{
+ * @substepnum 1
+ * @substepname cen_sbe_tp_chiplet_init1
+ * @substepdesc : Cen TP Chiplet Init 1
+ * @param target (CLASS_CHIP, TYPE_MEMBUF)
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 2
+ * @substepname cen_sbe_tp_arrayinit
+ * @substepdesc : Cen TP Chiplet array init
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 3
+ * @substepname cen_sbe_tp_chiplet_init2
+ * @substepdesc : Cen TP Chiplet Repair
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 4
+ * @substepname cen_sbe_tp_chiplet_init3
+ * @substepdesc : Cen TP Chiplet Start c0locks
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 5
+ * @substepname cen_sbe_chiplet_init
+ * @substepdesc : Cen Chiplet Init
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 6
+ * @substepname cen_sbe_arrayinit
+ * @substepdesc : Chiplet array init
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 7
+ * @substepname cen_sbe_pll_initf
+ * @substepdesc : Cen PLL Init
+ * @target_sched serial
+ * @}
+ * @{
+ * @substepnum 8
+ * @substepname cen_sbe_dts_init
+ * @substepdesc : Cen DTS Init
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 9
+ * @substepname cen_sbe_initf
+ * @substepdesc :Cen Scan overrides
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 10
+ * @substepname cen_sbe_do_manual_inits
+ * @substepdesc : Manual Cen Scans
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 11
+ * @substepname cen_sbe_startclocks
+ * @substepdesc : Start Cen Nest
+ * @target_sched serial
+ * @}
+ *
+ * @{
+ * @substepnum 12
+ * @substepname cen_sbe_scominits
+ * @substepdesc : Perform any Cen scom inits
+ * @target_sched serial
+ * @}
+ *
+ */
+
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
+
+namespace SBE_CENTAUR_INIT
+{
+
+ /**
+ * @brief cen_sbe_tp_chiplet_init1
+ *
+ * 10.1 : : Cen TP Chiplet Init 1
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_tp_chiplet_init1( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_tp_arrayinit
+ *
+ * 10.2 : Cen TP Chiplet array init
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_tp_arrayinit( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_tp_chiplet_init2
+ *
+ * 10.3 : Cen TP Chiplet Repair
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_tp_chiplet_init2( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_tp_chiplet_init3
+ *
+ * 10.4 : Cen TP Chiplet Start c0locks
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_tp_chiplet_init3( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_chiplet_init
+ *
+ * 10.5 : Cen Chiplet Init
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_chiplet_init( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_arrayinit
+ *
+ * 10.6 : Chiplet array init
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_arrayinit( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_pll_initf
+ *
+ * 10.7 : Cen PLL Init
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_pll_initf( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_dts_init
+ *
+ * 10.8 : Cen DTS Init
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_dts_init( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_initf
+ *
+ * 10.9 : Cen Scan overrides
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_initf( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_do_manual_inits
+ *
+ * 10.10 : Manual Cen Scans
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_do_manual_inits( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_startclocks
+ *
+ * 10.11 : Start Cen Nest
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_startclocks( void * io_pArgs );
+
+
+ /**
+ * @brief cen_sbe_scominits
+ *
+ * 10.12 : Perform any Cen scom inits
+ *
+ * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
+ * or NULL.
+ * return none
+ *
+ */
+ void call_cen_sbe_scominits( void * io_pArgs );
+
+}; // end namespace
+
+#endif
diff --git a/src/usr/hwpf/hwp/template.C b/src/usr/hwpf/hwp/template.C
deleted file mode 100644
index 395104c37..000000000
--- a/src/usr/hwpf/hwp/template.C
+++ /dev/null
@@ -1,126 +0,0 @@
-// IBM_PROLOG_BEGIN_TAG
-// This is an automatically generated prolog.
-//
-// $Source: src/usr/HWPs/template.C $
-//
-// IBM CONFIDENTIAL
-//
-// COPYRIGHT International Business Machines Corp. 2012
-//
-// p1
-//
-// Object Code Only (OCO) source materials
-// Licensed Internal Code Source Materials
-// IBM HostBoot Licensed Internal Code
-//
-// The source code for this program is not published or other-
-// wise divested of its trade secrets, irrespective of what has
-// been deposited with the U.S. Copyright Office.
-//
-// Origin: 30
-//
-// IBM_PROLOG_END
-
-// notes:
-// replace <@foo> with the tag string @foo
-// replace <<@foo>> with an uppercased tag string @foo
-
-/**
- * @file <@istepname>.C // @
- *
- * Support file for IStep:
- * <@istepname> // @
- *
- *
- *
- */
-
-
-/******************************************************************************/
-// Includes
-/******************************************************************************/
-#include <stdint.h>
-
-#include <kernel/console.H>
-#include <trace/interface.H>
-#include <initservice/taskargs.H>
-#include <errl/errlentry.H>
-#include <targeting/targetservice.H>
-#include <fapi.H>
-
-// -- prototype includes --
-#include "<@istepname>.H" // @
-#include "<@substepname>/<@substepname>.H" // @
-
-namespace <<@istepname>> // @
-{
-trace_desc_t *g_trac_<@istepname> = NULL; // @
-TRAC_INIT(&g_trac_dmi<@istepname>, "<<@istepname>>", 2048 ); // @
-
-using namespace TARGETING;
-
-//
-// Wrapper function to call <@istepnum>.<@substepnum> : <@substepname>
-//
-void call_<@substepname>( void *io_pArgs ) // @
-{
- INITSERVICE::TaskArgs *pTaskArgs =
- static_cast<INITSERVICE::TaskArgs *>( io_pArgs );
- fapi::ReturnCode l_fapirc;
-
- // Use hwasPredicate to filter only functional chips
- HWAS::HwasPredicate l_functionalHwas;
-
-
- TRACDCOMP( g_trac_dmi_training, "call_<@substepname> entry" ); //@
-
-
- // figure out what targets we need
-
- // print trace message beginning HWP, listing out input parms
- TRACFCOMP( g_trac_dmi_training,
- "===== Call @substepname HWP( @parm1 0x%x, ..., @parmN 0x%x ) : ",
- @parm1,
- ...,
- @parmN
- );
- // dump @target1..N Physical path
- EntityPath l_path;
- l_path = @target1->getAttr<ATTR_PHYS_PATH>();
- l_path.dump();
- // ...
- // dump @targetN
- EntityPath l_path;
- l_path = @targetN->getAttr<ATTR_PHYS_PATH>();
- l_path.dump();
-
- // call the HWP with each target ( if parallel, spin off a task )
- l_fapirc = <@substepname>( ? , ?, ? );
-
-
- // process return code.
- if ( l_fapirc == fapi::FAPI_RC_SUCCESS )
- {
- TRACFCOMP( g_trac_dmi_training,
- "SUCCESS : @substepname HWP( cpu 0x%x, mcs 0x%x, mem 0x%x ) " );
- }
- else
- {
- /**
- * @todo fapi error - just print out for now...
- */
- TRACFCOMP( g_trac_dmi_training,
- "ERROR %d: @substepname HWP( ) ",
- static_cast<uint32_t>(l_fapirc) );
- }
-
- TRACDCOMP( g_trac_dmi_training, "<@substepname> exit" ); //@
-
- // wait here on the barrier, then end the task.
- pTaskArgs->waitChildSync();
- task_end();
-}
-
-
-}; // end namespace
-
diff --git a/src/usr/hwpf/hwp/template.H b/src/usr/hwpf/hwp/template.H
deleted file mode 100644
index ae1dce967..000000000
--- a/src/usr/hwpf/hwp/template.H
+++ /dev/null
@@ -1,169 +0,0 @@
-// IBM_PROLOG_BEGIN_TAG
-// This is an automatically generated prolog.
-//
-// $Source: src/include/usr/hwas/hwas.H $
-//
-// IBM CONFIDENTIAL
-//
-// COPYRIGHT International Business Machines Corp. 2011
-//
-// p1
-//
-// Object Code Only (OCO) source materials
-// Licensed Internal Code Source Materials
-// IBM HostBoot Licensed Internal Code
-//
-// The source code for this program is not published or other-
-// wise divested of its trade secrets, irrespective of what has
-// been deposited with the U.S. Copyright Office.
-//
-// Origin: 30
-//
-// IBM_PROLOG_END
-
-/**
- * @subpage Generating new HWP
- *
- * Hopefully we can automate this, if not, the tag file should still be
- * generated by the HWP writer.
- * template files for istep<@istepnum>list.H, and <@istepname.H> have have
- * been provided.
- *
- * Please consult the latest version of Dean's document
- * HostBoot IPL Flow for VPL and PgP
- * to get IStep names, IStep numbers, substep numbers, etc.
- *
- * Note:
- * <@istepname> is the IStep name stated in Dean's document, with
- * '_' substituted for spaces.
- * For example, dmi_training.
- * <@substepname> is the substep name stated in Dean's document, with '_'
- * substituted for spaces.
- * for example, proc_cen_framelock
- *
- * To set up to run a new HWP, follow these directions
- * ( or have your perlscript do it from the tag block )
- *
- * Make up a new directory src/usr/HWPs/<@istepname>
- * Make up a new directory src/usr/HWPs/<@istepname>/<@substepname>
- * Copy code for new HWP to src/usr/HWPs/<@istepname>/<@substepname>. using git.
- * For example, to set up for istep 11.7, proc_gen_framelock :
- * ## cutNpaste the fetch comand from Gerrit. See the webpage at
- * ## http://gfw160.austin.ibm.com:8080/gerrit/#change,597
- * git fetch ssh://wenning@gfw160.austin.ibm.com:29418/hwp_review_centaur refs/changes/97/597/3
- * ## then run the git command to put the code in the right directory:
- * git diff FETCH_HEAD FETCH_HEAD~1 -R | git apply --directory=src/usr/HWPs/dmi_training/proc_gen_framelock
- *
- * Part of the HWP source should be a <@substep>.xml file .
- * Add the <@substep>.xml file (actually any xml files) to src/usr/hwpf/hwp
- * and update hwpf/makefile to process the xml file
- *
- * Make up a new file src/usr/HWPs/<@istepname>/<@istepname.H> (use src/usr/HWPs/template.H as a template)
- * Make up a new file src/usr/HWPs/<@istepname>/<@istepname.C> (use src/usr/HWPs/template.C as a template)
- * Make up new makefile src/usr/HWPs/<@istepname>/makefile to compile the HWP and wrapper
- * Make sure you add the lines
- * ## pointer to common HWP files
- * EXTRAINCDIR += ${ROOTPATH}/src/usr/HWPs/include
- * to the makefiles.
- *
- *
- * * Update all the other makefiles:
- * src/usr/HWPs/makefile
- * src/usr/makefile
- * src/makefile
- *
- *
- * Add a tag block inside <@istepname>.H ( for now, I would like to see this
- * inside the HWP source) with all the information on the
- * istep. An example tag block for IStep 11.7, DMI Training, proc_cen_framelock
- * is below.
- * The tag block will be used to modify and create framework files
- * to support the hardware procedure.
- *
- * Modify:
- * src/include/usr/istepmasterlist.H
- * src/usr/HWPs/<@istepname>/<@istepname>.H
- * src/usr/HWPs/<@istepname>/<@istepname>.C
- * Create:
- * src/include/usr/istep<@istepname>list.H
- *
- * The tag block keywords, with explanations, are as follows:
- * * @tag isteplist
- * - should be at the beginning of the block to tell the (mythical) perl
- * script that this will generate an IStep wrapper for an HWP
- *
- * * @docversion (version # of Dean's IPL document)
- * - adds a comment to istep<@istepname>list.H
- *
- * * @istepname ( istep name from Dean's IPL document )
- * - creates a namespace ISTEP_NAME, i.e. uppercased <@istepame>
- * in <@istepname>.C and <@istepname>.H
- * - creates a new module id in src/include/usr/initsvcreasoncodes.H
- * - creates a modulename string "<@istepname>.so" for istep<@istepnum>list.H
- * - ?
- *
- * * @istepnum (istep number from Dean's IPL document)
- * - creates a new istep<@istepnum>list.H file in /usr/include/isteps/
- * - adds the new istep<@istepnum>list.H file to src/include/usr/istepmasterlist.H
- * in the correct place in the master istep list.
- * - sets the istep number in the ISTEPNAME() macro in istep<@istepnum>list.H
- * * @istepdesc ( description of istep from Dean's document )
- * - creates comments in istep<@istepnum>list.H file
- *
- * -- one or more substep blocks enclosed by @{ .. @}
- * @{
- * * @substepname (substepname from Dean's document)
- * - creates a prototype for <@substepname>
- *
- * * @substepnum ( number of substep from Dean's document )
- * - sets the istep number in the ISTEPNAME() macro in istep<@istepnum>list.H
- *
- * @target_sched ( serial or parallel )
- * - will attempt to run each target either serially or in parallel
- *
- * -- 0 or more target types to be used as parameters to HWP
- * TBD needs work
- * @target_type (type or class of targets that this HWP should run under)
- * - adds code to find the targets used in TARGETING
- * @}
- */
-
-
-#ifndef __<@istepname>_<@istepname>_H
-#define __<@istepname>_<@istepname>_H
-/**
- * @file <@istepname>.H
- *
- * <@istepname>
- *
- * All of the following routines are "named isteps" - they are invoked as
- * tasks by the @ref IStepDispatcher.
- *
- */
-
-
-/******************************************************************************/
-// Includes
-/******************************************************************************/
-#include <stdint.h>
-
-
-namespace <@istepname>
-{
-
- /**
- * @brief <@substepname>
- *
- * <@istepnum>.<@substepnum> : <@substepdesc>
- *
- * param[in,out] io_pArgs - (normally) a pointer to a TaskArgs struct,
- * or NULL.
- * return none
- *
- */
- void call_<@substepname>( void * io_pArgs );
-
-
-}; // end namespace
-
-#endif
diff --git a/src/usr/initservice/istepdispatcher/istepdispatcher.C b/src/usr/initservice/istepdispatcher/istepdispatcher.C
index 62df12dde..46f61fff8 100644
--- a/src/usr/initservice/istepdispatcher/istepdispatcher.C
+++ b/src/usr/initservice/istepdispatcher/istepdispatcher.C
@@ -46,6 +46,8 @@
#include <errl/errlentry.H> // errlHndl_t
#include <devicefw/userif.H> // targeting
+#include <initservice/isteps_trace.H> // ISTEPS_TRACE buffer
+
#include <initservice/taskargs.H> // TaskArgs structs
#include <errl/errluserdetails.H> // ErrlUserDetails base class
@@ -62,6 +64,15 @@
#include <isteps/istepmasterlist.H>
#include <targeting/util.H>
+// ----- namespace ISTEPS_TRACE ---------------------------------------
+namespace ISTEPS_TRACE
+{
+
+// declare storage for isteps_trace!
+trace_desc_t *g_trac_isteps_trace = NULL;
+
+} // end namespace
+// ----- end namespace ISTEPS_TRACE -----------------------------------
// ----- namespace ERRORLOG -------------------------------------------
namespace ERRORLOG
@@ -174,13 +185,6 @@ const TaskInfo *IStepDispatcher::findTaskInfo(
break;
}
- TRACDCOMP( g_trac_initsvc,
- "g_isteps[0x%x].numitems = 0x%x (substep=0x%x)",
- i_IStep,
- g_isteps[i_IStep].numitems,
- i_SubStep );
-
-
// check input range - IStep
if ( i_IStep >= MAX_ISTEPS )
{
@@ -248,6 +252,14 @@ void IStepDispatcher::init( void * io_ptr )
{
// note, io_ptr will pass the TaskArgs struct through to runAllSteps, etc.
+ // initialize (and declare) ISTEPS_TRACE here, the rest of the isteps will use it.
+ ISTEPS_TRACE::g_trac_isteps_trace = NULL;
+ TRAC_INIT(&ISTEPS_TRACE::g_trac_isteps_trace, "ISTEPS_TRACE", 2048 );
+
+ TRACDCOMP( ISTEPS_TRACE::g_trac_isteps_trace,
+ "ISTEPS_TRACE buffer %p created.",
+ ISTEPS_TRACE::g_trac_isteps_trace );
+
if ( getIStepMode() )
{
TRACFCOMP( g_trac_initsvc,
@@ -357,7 +369,7 @@ void IStepDispatcher::processSingleIStepCmd(
l_sts.substep = l_cmd.substep;
l_sts.istepStatus = 0;
- TRACFCOMP( g_trac_initsvc,
+ TRACDCOMP( g_trac_initsvc,
"processSingleIStepCmd: Running IStep=%d, SubStep=%d",
l_cmd.istep,
l_cmd.substep );
@@ -415,6 +427,11 @@ void IStepDispatcher::processSingleIStepCmd(
uint64_t l_progresscode = ( (l_cmd.istep<<16) | l_cmd.substep );
InitService::getTheInstance().setProgressCode( l_progresscode );
+ TRACFCOMP( g_trac_initsvc,
+ "processSingleIStepCmd: Running IStep=%d, SubStep=%d %s",
+ l_cmd.istep,
+ l_cmd.substep,
+ l_pistep->taskname );
// clear the TaskArgs struct
l_taskargs.clear();
@@ -661,7 +678,9 @@ void IStepDispatcher::runAllISteps( void * io_ptr ) const
// print out what we are running
TRACFCOMP( g_trac_initsvc,
- "Running IStep %s",
+ "Run IStep %d.%d %s",
+ l_IStep,
+ l_SubStep,
l_pistep->taskname );
OpenPOWER on IntegriCloud