summaryrefslogtreecommitdiffstats
path: root/src/usr/hwpf/hwp/secure_boot
diff options
context:
space:
mode:
authorDan Crowell <dcrowell@us.ibm.com>2016-08-26 10:03:53 -0500
committerDaniel M. Crowell <dcrowell@us.ibm.com>2016-08-30 17:22:01 -0400
commitab651844afcc9b0ac6a1c74779da555b62342bf1 (patch)
treea2237315dc22c11545d00f4f97aea7645028f5ef /src/usr/hwpf/hwp/secure_boot
parent85cb1f757c9de446ab4e1f460e206091242b2c49 (diff)
downloadblackbird-hostboot-ab651844afcc9b0ac6a1c74779da555b62342bf1.tar.gz
blackbird-hostboot-ab651844afcc9b0ac6a1c74779da555b62342bf1.zip
Remove last of old hwpf directory
Remove all of the old fapi1 HWPs from P8 Update makefiles/code to not include old hwpf headers Change-Id: Idc840554721f68b0af3b6ee6c7ad84f5df258e60 RTC: 146345 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/28844 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com> Reviewed-by: Thi N. Tran <thi@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/usr/hwpf/hwp/secure_boot')
-rw-r--r--src/usr/hwpf/hwp/secure_boot/makefile52
-rw-r--r--src/usr/hwpf/hwp/secure_boot/proc_check_security.C100
-rw-r--r--src/usr/hwpf/hwp/secure_boot/proc_check_security.H79
-rw-r--r--src/usr/hwpf/hwp/secure_boot/proc_sbe_scan_service.H49
-rw-r--r--src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.C295
-rw-r--r--src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.H79
-rw-r--r--src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.C148
-rw-r--r--src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.H80
8 files changed, 0 insertions, 882 deletions
diff --git a/src/usr/hwpf/hwp/secure_boot/makefile b/src/usr/hwpf/hwp/secure_boot/makefile
deleted file mode 100644
index f010e90c7..000000000
--- a/src/usr/hwpf/hwp/secure_boot/makefile
+++ /dev/null
@@ -1,52 +0,0 @@
-# IBM_PROLOG_BEGIN_TAG
-# This is an automatically generated prolog.
-#
-# $Source: src/usr/hwpf/hwp/secure_boot/makefile $
-#
-# OpenPOWER HostBoot Project
-#
-# Contributors Listed Below - COPYRIGHT 2015
-# [+] International Business Machines Corp.
-#
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
-# implied. See the License for the specific language governing
-# permissions and limitations under the License.
-#
-# IBM_PROLOG_END_TAG
-
-ROOTPATH = ../../../../..
-
-MODULE = secure_boot
-
-## 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/secure_boot
-EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/slave_sbe/proc_cen_ref_clk_enable
-EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/slave_sbe/proc_check_slave_sbe_seeprom_complete
-EXTRAINCDIR += ${ROOTPATH}/src/usr/hwpf/hwp/core_activate/proc_stop_deadman_timer
-
-OBJS += proc_check_security.o
-OBJS += proc_stop_sbe_scan_service.o
-OBJS += proc_use_sbe_scan_service.o
-
-## NOTE: add a new directory onto the vpaths when you add a new HWP
-VPATH += ${ROOTPATH}/src/usr/hwpf/hwp/secure_boot
-
-include ${ROOTPATH}/config.mk
diff --git a/src/usr/hwpf/hwp/secure_boot/proc_check_security.C b/src/usr/hwpf/hwp/secure_boot/proc_check_security.C
deleted file mode 100644
index 9514ef4b7..000000000
--- a/src/usr/hwpf/hwp/secure_boot/proc_check_security.C
+++ /dev/null
@@ -1,100 +0,0 @@
-/* IBM_PROLOG_BEGIN_TAG */
-/* This is an automatically generated prolog. */
-/* */
-/* $Source: src/usr/hwpf/hwp/secure_boot/proc_check_security.C $ */
-/* */
-/* OpenPOWER HostBoot Project */
-/* */
-/* Contributors Listed Below - COPYRIGHT 2015 */
-/* [+] International Business Machines Corp. */
-/* */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); */
-/* you may not use this file except in compliance with the License. */
-/* You may obtain a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
-/* implied. See the License for the specific language governing */
-/* permissions and limitations under the License. */
-/* */
-/* IBM_PROLOG_END_TAG */
-// $Id: proc_check_security.C,v 1.2 2015/08/03 14:04:43 thi Exp $
-// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/chips/p8/working/procedures/ipl/fapi/proc_check_security.C,v $
-//------------------------------------------------------------------------------
-// *|
-// *! (C) Copyright International Business Machines Corp. 2015
-// *! All Rights Reserved -- Property of IBM
-// *! *** ***
-// *|
-// *! TITLE : proc_check_security.C
-// *! DESCRIPTION : Determine state of processor security controls
-// *!
-// *! OWNER NAME : Joe McGill Email: jmcgill@us.ibm.com
-// *!
-//------------------------------------------------------------------------------
-
-
-//------------------------------------------------------------------------------
-// Includes
-//------------------------------------------------------------------------------
-#include <p8_scom_addresses.H>
-#include <proc_check_security.H>
-
-
-//------------------------------------------------------------------------------
-// Constant definitions
-//------------------------------------------------------------------------------
-
-// Security Switch register field/bit definitions
-const uint32_t OTPC_M_SECURITY_SWITCH_TRUSTED_BOOT_BIT = 1;
-
-
-//------------------------------------------------------------------------------
-// Function definitions
-//------------------------------------------------------------------------------
-
-extern "C"
-{
-
-//------------------------------------------------------------------------------
-// function:
-// Determine state of processor security controls
-//
-// parameters: i_target => chip target
-// o_secure => true if security enabled, else false
-// returns: FAPI_RC_SUCCESS if operation was successful, else error
-//------------------------------------------------------------------------------
-fapi::ReturnCode proc_check_security(
- const fapi::Target& i_target,
- bool & o_secure)
-{
- // return codes
- fapi::ReturnCode rc;
-
- // mark function entry
- FAPI_DBG("Start");
-
- do
- {
- ecmdDataBufferBase security_switch_data(64);
- rc = fapiGetScom(i_target, OTPC_M_SECURITY_SWITCH_0x00010005, security_switch_data);
- if (!rc.ok())
- {
- FAPI_ERR("Error reading Security Switch Register");
- break;
- }
- o_secure = security_switch_data.isBitSet(OTPC_M_SECURITY_SWITCH_TRUSTED_BOOT_BIT);
-
- } while(0);
-
- // mark function entry
- FAPI_DBG("End");
- return rc;
-}
-
-
-} // extern "C"
diff --git a/src/usr/hwpf/hwp/secure_boot/proc_check_security.H b/src/usr/hwpf/hwp/secure_boot/proc_check_security.H
deleted file mode 100644
index 8cad2b975..000000000
--- a/src/usr/hwpf/hwp/secure_boot/proc_check_security.H
+++ /dev/null
@@ -1,79 +0,0 @@
-/* IBM_PROLOG_BEGIN_TAG */
-/* This is an automatically generated prolog. */
-/* */
-/* $Source: src/usr/hwpf/hwp/secure_boot/proc_check_security.H $ */
-/* */
-/* OpenPOWER HostBoot Project */
-/* */
-/* Contributors Listed Below - COPYRIGHT 2015 */
-/* [+] International Business Machines Corp. */
-/* */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); */
-/* you may not use this file except in compliance with the License. */
-/* You may obtain a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
-/* implied. See the License for the specific language governing */
-/* permissions and limitations under the License. */
-/* */
-/* IBM_PROLOG_END_TAG */
-// $Id: proc_check_security.H,v 1.1 2015/05/14 21:16:40 jmcgill Exp $
-// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/chips/p8/working/procedures/ipl/fapi/proc_check_security.H,v $
-//------------------------------------------------------------------------------
-// *|
-// *! (C) Copyright International Business Machines Corp. 2015
-// *! All Rights Reserved -- Property of IBM
-// *! *** ***
-// *|
-// *! TITLE : proc_check_security.H
-// *! DESCRIPTION : Determine state of processor security controls
-// *!
-// *! OWNER NAME : Joe McGill Email: jmcgill@us.ibm.com
-// *!
-//------------------------------------------------------------------------------
-
-#ifndef _PROC_CHECK_SECURITY_H_
-#define _PROC_CHECK_SECURITY_H_
-
-//------------------------------------------------------------------------------
-// Includes
-//------------------------------------------------------------------------------
-#include <fapi.H>
-
-
-//------------------------------------------------------------------------------
-// Function prototypes
-//------------------------------------------------------------------------------
-
-// function pointer typedef definition for HWP call support
-typedef fapi::ReturnCode (*proc_check_security_FP_t)(const fapi::Target &, bool &);
-
-
-//------------------------------------------------------------------------------
-// Function prototypes
-//------------------------------------------------------------------------------
-
-extern "C"
-{
-
-//------------------------------------------------------------------------------
-// function:
-// Determine state of processor security controls
-//
-// parameters: i_target => chip target
-// o_secure => true if security enabled, else false
-// returns: FAPI_RC_SUCCESS if operation was successful, else error
-//------------------------------------------------------------------------------
-fapi::ReturnCode proc_check_security(
- const fapi::Target& i_target,
- bool & o_secure);
-
-
-} // extern "C"
-
-#endif // _PROC_CHECK_SECURITY_H_
diff --git a/src/usr/hwpf/hwp/secure_boot/proc_sbe_scan_service.H b/src/usr/hwpf/hwp/secure_boot/proc_sbe_scan_service.H
deleted file mode 100644
index cb5a88027..000000000
--- a/src/usr/hwpf/hwp/secure_boot/proc_sbe_scan_service.H
+++ /dev/null
@@ -1,49 +0,0 @@
-/* IBM_PROLOG_BEGIN_TAG */
-/* This is an automatically generated prolog. */
-/* */
-/* $Source: src/usr/hwpf/hwp/secure_boot/proc_sbe_scan_service.H $ */
-/* */
-/* OpenPOWER HostBoot Project */
-/* */
-/* Contributors Listed Below - COPYRIGHT 2015 */
-/* [+] International Business Machines Corp. */
-/* */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); */
-/* you may not use this file except in compliance with the License. */
-/* You may obtain a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
-/* implied. See the License for the specific language governing */
-/* permissions and limitations under the License. */
-/* */
-/* IBM_PROLOG_END_TAG */
-// $Id: proc_sbe_scan_service.H,v 1.1 2015/05/14 22:23:55 jmcgill Exp $
-
-/// Substep numbers for the proc_sbe_scan_service procedure
-
-#ifndef __PROC_SBE_SCAN_SERVICE_H
-#define __PROC_SBE_SCAN_SERVICE_H
-
-#include "fapi_sbe_common.H"
-#include "sbe_vital.H"
-
-//NOTE: The following values must stay constant as HB looks for them
-CONST_UINT8_T(SUBSTEP_PROC_ENTRY, ULL(0x0));
-CONST_UINT8_T(SUBSTEP_SBE_READY, ULL(0x1));
-CONST_UINT8_T(SUBSTEP_DECODE_REQ, ULL(0x2));
-CONST_UINT8_T(SUBSTEP_SCAN_IP, ULL(0x3));
-CONST_UINT8_T(SUBSTEP_SCAN_PRE_BRANCH, ULL(0x4));
-CONST_UINT8_T(SUBSTEP_SCAN_IN_BRANCH, ULL(0x5));
-CONST_UINT8_T(SUBSTEP_SCAN_DONE, ULL(0x6));
-CONST_UINT8_T(SUBSTEP_SCAN_POST_BRANCH, ULL(0x7));
-CONST_UINT8_T(SUBSTEP_RESCAN_IP, ULL(0x8));
-CONST_UINT8_T(SUBSTEP_RESCAN_CHECKWORD_ERR, ULL(0xD));
-CONST_UINT8_T(SUBSTEP_ARG_ERR, ULL(0xE));
-CONST_UINT8_T(SUBSTEP_HALT_SUCCESS, ULL(0xF));
-
-#endif // __PROC_SBE_SCAN_SERVICE_H
diff --git a/src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.C b/src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.C
deleted file mode 100644
index bedad0b7e..000000000
--- a/src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.C
+++ /dev/null
@@ -1,295 +0,0 @@
-/* IBM_PROLOG_BEGIN_TAG */
-/* This is an automatically generated prolog. */
-/* */
-/* $Source: src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.C $ */
-/* */
-/* OpenPOWER HostBoot Project */
-/* */
-/* Contributors Listed Below - COPYRIGHT 2015 */
-/* [+] International Business Machines Corp. */
-/* */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); */
-/* you may not use this file except in compliance with the License. */
-/* You may obtain a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
-/* implied. See the License for the specific language governing */
-/* permissions and limitations under the License. */
-/* */
-/* IBM_PROLOG_END_TAG */
-// $Id: proc_stop_sbe_scan_service.C,v 1.2 2015/07/27 00:48:38 jmcgill Exp $
-// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/chips/p8/working/procedures/ipl/fapi/proc_stop_sbe_scan_service.C,v $
-//------------------------------------------------------------------------------
-// *|
-// *! (C) Copyright International Business Machines Corp. 2015
-// *! All Rights Reserved -- Property of IBM
-// *! *** ***
-// *|
-// *! TITLE : proc_stop_sbe_scan_service.C
-// *! DESCRIPTION : Stop SBE runtime scan service
-// *!
-// *! OWNER NAME : Joe McGill Email: jmcgill@us.ibm.com
-// *!
-//------------------------------------------------------------------------------
-
-
-//------------------------------------------------------------------------------
-// Includes
-//------------------------------------------------------------------------------
-#include <proc_stop_sbe_scan_service.H>
-#include <p8_scom_addresses.H>
-#include <p8_istep_num.H>
-#include <proc_sbe_scan_service.H>
-#include <proc_use_sbe_scan_service.H>
-#include <proc_extract_sbe_rc.H>
-#include <proc_reset_i2cm_bus_fence.H>
-#include <proc_sbe_utils.H>
-
-
-//------------------------------------------------------------------------------
-// Constant definitions
-//------------------------------------------------------------------------------
-
-// SBE progress constants
-const uint8_t SBE_EXIT_SUCCESS_0xF = 0xF;
-
-// SBE polling constants
-const uint32_t SBE_HALT_POLL_MAX_LOOPS = 10;
-const uint32_t SBE_HALT_POLL_DELAY_HW = 2000000;
-const uint32_t SBE_HALT_POLL_DELAY_SIM = 10000000;
-
-// SBE Mailbox0 Register scan request format constants
-const uint32_t MBOX0_REQUEST_VALID_BIT = 0;
-const uint32_t MBOX0_HALT_PATTERN_START_BIT = 16;
-const uint32_t MBOX0_HALT_PATTERN_END_BIT = 31;
-const uint32_t MBOX0_HALT_PATTERN = 0xD05E;
-
-//------------------------------------------------------------------------------
-// Function definitions
-//------------------------------------------------------------------------------
-
-extern "C"
-{
-
-//------------------------------------------------------------------------------
-// function:
-// Stop SBE runtime scan service
-//
-// parameters: i_target => chip target
-// returns: FAPI_RC_SUCCESS if operation was successful, else error
-//------------------------------------------------------------------------------
-fapi::ReturnCode proc_stop_sbe_scan_service(
- const fapi::Target& i_target,
- const void* i_pSEEPROM)
-{
- // return codes
- fapi::ReturnCode rc;
- uint32_t rc_ecmd = 0;
-
- // track if procedure has cleared I2C master bus fence
- bool i2cm_bus_fence_cleared = false;
-
- // mark function entry
- FAPI_DBG("Start");
-
- do
- {
- // check SBE progress
- bool sbe_running = true;
- size_t loop_time = 0;
- uint8_t halt_code = 0;
- uint16_t istep_num = 0;
- uint8_t substep_num = 0;
- bool scan_service_loop_reached = false;
-
- // retrieve status
- rc = proc_sbe_utils_check_status(
- i_target,
- sbe_running,
- halt_code,
- istep_num,
- substep_num);
- if (!rc.ok())
- {
- FAPI_ERR("Error from proc_check_sbe_state_check_status");
- break;
- }
-
- // get HB->SBE request mailbox, check that it is clear
- ecmdDataBufferBase mbox_data(64);
- bool sbe_ready = false;
- rc = fapiGetScom(i_target, MBOX_SCRATCH_REG0_0x00050038, mbox_data);
- if (!rc.ok())
- {
- FAPI_ERR("Scom error reading SBE MBOX0 Register");
- break;
- }
- sbe_ready = (mbox_data.getDoubleWord(0) == 0);
-
- scan_service_loop_reached =
- sbe_running &&
- sbe_ready &&
- !halt_code &&
- (istep_num == PROC_SBE_SCAN_SERVICE_ISTEP_NUM) &&
- (substep_num == SUBSTEP_SBE_READY);
-
- FAPI_INF("SBE is running [%d], loop time [%zd], scan service loop reached [%d]",
- sbe_running, loop_time, scan_service_loop_reached);
-
- if (!sbe_running)
- {
- FAPI_INF("SBE is stopped, exiting!");
- break;
- }
- else if (scan_service_loop_reached)
- {
- // format stop request
- rc_ecmd |= mbox_data.setBit(MBOX0_REQUEST_VALID_BIT);
- rc_ecmd |= mbox_data.insertFromRight(MBOX0_HALT_PATTERN,
- MBOX0_HALT_PATTERN_START_BIT,
- (MBOX0_HALT_PATTERN_END_BIT-
- MBOX0_HALT_PATTERN_START_BIT)+1);
- if (rc_ecmd)
- {
- FAPI_ERR("Error 0x%x setting up SBE MBOX0 data buffer.", rc_ecmd);
- rc.setEcmdError(rc_ecmd);
- break;
- }
-
- // submit stop request to SBE
- FAPI_DBG("Submitting stop request to SBE");
- rc = fapiPutScom(i_target, MBOX_SCRATCH_REG0_0x00050038, mbox_data);
- if (!rc.ok())
- {
- FAPI_ERR("Error writing SBE MBOX0 Register");
- break;
- }
-
- // pause to allow request to be processed
- uint32_t loop_num = 0;
- while (sbe_running && (loop_num < SBE_HALT_POLL_MAX_LOOPS))
- {
- loop_num++;
- rc = fapiDelay(SBE_HALT_POLL_DELAY_HW, SBE_HALT_POLL_DELAY_SIM);
- if (!rc.ok())
- {
- FAPI_ERR("Error from fapiDelay");
- break;
- }
-
- // retrieve status
- rc = proc_sbe_utils_check_status(
- i_target,
- sbe_running,
- halt_code,
- istep_num,
- substep_num);
- if (!rc.ok())
- {
- FAPI_ERR("Error from proc_check_sbe_state_check_status");
- break;
- }
- }
- if (rc)
- {
- break;
- }
- if (sbe_running)
- {
- FAPI_ERR("SBE is STILL running!");
- const fapi::Target & TARGET = i_target;
- FAPI_SET_HWP_ERROR(rc, RC_PROC_STOP_SBE_SCAN_SERVICE_SBE_NOT_STOPPED);
- break;
- }
-
- // before analysis proceeds, make sure that I2C master bus fence is cleared
- FAPI_EXEC_HWP(rc, proc_reset_i2cm_bus_fence, i_target);
- if (!rc.ok())
- {
- FAPI_ERR("Error from proc_reset_i2cm_bus_fence");
- break;
- }
- // mark that fence has been cleared
- i2cm_bus_fence_cleared = true;
-
- // ensure correct halt code is captured
- rc = proc_sbe_utils_check_status(
- i_target,
- sbe_running,
- halt_code,
- istep_num,
- substep_num);
- if (!rc.ok())
- {
- FAPI_ERR("Error from proc_check_sbe_state_check_status");
- break;
- }
-
- // confirm that expected halt point was reached
- if (halt_code != SBE_EXIT_SUCCESS_0xF)
- {
- FAPI_ERR("SBE halted with error 0x%X (istep 0x%03X, substep 0x%X)",
- halt_code, istep_num, substep_num);
- // extract & return error code from analyzing SBE state
- FAPI_EXEC_HWP(rc, proc_extract_sbe_rc, i_target, NULL, i_pSEEPROM, SBE);
- break;
- }
-
- if ((istep_num != PROC_SBE_SCAN_SERVICE_ISTEP_NUM) ||
- (substep_num != SUBSTEP_HALT_SUCCESS))
- {
- FAPI_ERR("Expected SBE istep 0x%03llX, substep 0x%X but found istep 0x%03X, substep 0x%X",
- PROC_SBE_SCAN_SERVICE_ISTEP_NUM, SUBSTEP_HALT_SUCCESS,
- istep_num, substep_num);
- const fapi::Target & TARGET = i_target;
- const uint32_t & ISTEP_NUM = istep_num;
- const uint32_t & SUBSTEP_NUM = substep_num;
- FAPI_SET_HWP_ERROR(rc, RC_PROC_STOP_SBE_SCAN_SERVICE_SBE_BAD_HALT);
- break;
- }
-
- // Reset the SBE so it can be used for MPIPL if needed
- ecmdDataBufferBase sbe_reset_data(64);
- rc = fapiPutScom(i_target, PORE_SBE_RESET_0x000E0002, sbe_reset_data);
- if (!rc.ok())
- {
- FAPI_ERR("Scom error resetting SBE\n");
- break;
- }
- }
- // error
- else
- {
- FAPI_ERR("SBE did not reach acceptable final state!");
- const fapi::Target & TARGET = i_target;
- const bool & SBE_RUNNING = sbe_running;
- const uint8_t & HALT_CODE = halt_code;
- const uint16_t & ISTEP_NUM = istep_num;
- const uint8_t & SUBSTEP_NUM = substep_num;
- FAPI_SET_HWP_ERROR(rc, RC_PROC_STOP_SBE_SCAN_SERVICE_UNEXPECTED_FINAL_STATE);
- break;
- }
-
- } while(0);
-
- // if an error occurred prior to the I2C master bus fence
- // being cleared, attempt to clear it prior to exit
- if (!rc.ok() && !i2cm_bus_fence_cleared)
- {
- // discard rc, return that of original fail
- fapi::ReturnCode rc_unused;
- FAPI_EXEC_HWP(rc_unused, proc_reset_i2cm_bus_fence, i_target);
- }
-
- // mark function entry
- FAPI_DBG("End");
- return rc;
-}
-
-
-} // extern "C"
diff --git a/src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.H b/src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.H
deleted file mode 100644
index 4ee6d97f6..000000000
--- a/src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.H
+++ /dev/null
@@ -1,79 +0,0 @@
-/* IBM_PROLOG_BEGIN_TAG */
-/* This is an automatically generated prolog. */
-/* */
-/* $Source: src/usr/hwpf/hwp/secure_boot/proc_stop_sbe_scan_service.H $ */
-/* */
-/* OpenPOWER HostBoot Project */
-/* */
-/* Contributors Listed Below - COPYRIGHT 2015 */
-/* [+] International Business Machines Corp. */
-/* */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); */
-/* you may not use this file except in compliance with the License. */
-/* You may obtain a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
-/* implied. See the License for the specific language governing */
-/* permissions and limitations under the License. */
-/* */
-/* IBM_PROLOG_END_TAG */
-// $Id: proc_stop_sbe_scan_service.H,v 1.1 2015/05/14 21:25:17 jmcgill Exp $
-// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/chips/p8/working/procedures/ipl/fapi/proc_stop_sbe_scan_service.H,v $
-//------------------------------------------------------------------------------
-// *|
-// *! (C) Copyright International Business Machines Corp. 2015
-// *! All Rights Reserved -- Property of IBM
-// *! *** ***
-// *|
-// *! TITLE : proc_stop_sbe_scan_service.H
-// *! DESCRIPTION : Stop SBE runtime scan service
-// *!
-// *! OWNER NAME : Joe McGill Email: jmcgill@us.ibm.com
-// *!
-//------------------------------------------------------------------------------
-
-#ifndef _PROC_STOP_SBE_SCAN_SERVICE_H_
-#define _PROC_STOP_SBE_SCAN_SERVICE_H_
-
-//------------------------------------------------------------------------------
-// Includes
-//------------------------------------------------------------------------------
-#include <fapi.H>
-
-
-//------------------------------------------------------------------------------
-// Function prototypes
-//------------------------------------------------------------------------------
-
-// function pointer typedef definition for HWP call support
-typedef fapi::ReturnCode (*proc_stop_sbe_scan_service_FP_t)(const fapi::Target &,
- const void *);
-
-
-//------------------------------------------------------------------------------
-// Function prototypes
-//------------------------------------------------------------------------------
-
-extern "C"
-{
-
-//------------------------------------------------------------------------------
-// function:
-// Stop SBE runtime scan service
-//
-// parameters: i_target => chip target
-// returns: FAPI_RC_SUCCESS if operation was successful, else error
-//------------------------------------------------------------------------------
-fapi::ReturnCode proc_stop_sbe_scan_service(
- const fapi::Target& i_target,
- const void *);
-
-
-} // extern "C"
-
-#endif // _PROC_STOP_SBE_SCAN_SERVICE_H_
diff --git a/src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.C b/src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.C
deleted file mode 100644
index b24bc416e..000000000
--- a/src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.C
+++ /dev/null
@@ -1,148 +0,0 @@
-/* IBM_PROLOG_BEGIN_TAG */
-/* This is an automatically generated prolog. */
-/* */
-/* $Source: src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.C $ */
-/* */
-/* OpenPOWER HostBoot Project */
-/* */
-/* Contributors Listed Below - COPYRIGHT 2015 */
-/* [+] International Business Machines Corp. */
-/* */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); */
-/* you may not use this file except in compliance with the License. */
-/* You may obtain a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
-/* implied. See the License for the specific language governing */
-/* permissions and limitations under the License. */
-/* */
-/* IBM_PROLOG_END_TAG */
-// $Id: proc_use_sbe_scan_service.C,v 1.1 2015/05/14 21:49:17 jmcgill Exp $
-// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/chips/p8/working/procedures/ipl/fapi/proc_use_sbe_scan_service.C,v $
-//------------------------------------------------------------------------------
-// *|
-// *! (C) Copyright International Business Machines Corp. 2015
-// *! All Rights Reserved -- Property of IBM
-// *! *** ***
-// *|
-// *! TITLE : proc_use_sbe_scan_service.C
-// *! DESCRIPTION : Shared routine used to determine use of SBE runtime scan
-// *! service
-// *!
-// *! OWNER NAME : Joe McGill Email: jmcgill@us.ibm.com
-// *!
-//------------------------------------------------------------------------------
-
-
-//------------------------------------------------------------------------------
-// Includes
-//------------------------------------------------------------------------------
-#include <p8_scom_addresses.H>
-#include <proc_use_sbe_scan_service.H>
-#include <proc_check_master_sbe_seeprom.H>
-#include <proc_check_security.H>
-
-//------------------------------------------------------------------------------
-// Constant definitions
-//------------------------------------------------------------------------------
-
-//------------------------------------------------------------------------------
-// Function definitions
-//------------------------------------------------------------------------------
-
-extern "C"
-{
-
-//------------------------------------------------------------------------------
-// function:
-// Use SBE runtime scan service?
-//
-// parameters: i_target => chip target
-// returns: FAPI_RC_SUCCESS if operation was successful, else error
-//------------------------------------------------------------------------------
-fapi::ReturnCode proc_use_sbe_scan_service(
- const fapi::Target& i_target,
- bool& o_use_sbe_scan_service)
-{
- // return codes
- fapi::ReturnCode rc;
-
- // mark function entry
- FAPI_DBG("Start");
-
- do
- {
- // make determination of scan path to use
- // use SBE scan service if:
- // processor chip target AND
- // slave chip AND
- // ((secure boot enabled OR ATTR_FORCE_USE_SBE_SLAVE_SCAN_SERVICE) AND !ATTR_TRUSTED_SLAVE_SCAN_PATH_ACTIVE)
-
- // check for processor chip target
- o_use_sbe_scan_service = (i_target.getType() == fapi::TARGET_TYPE_PROC_CHIP);
- // check for slave chip
- if (o_use_sbe_scan_service)
- {
- bool is_master;
- FAPI_EXEC_HWP(rc, proc_check_master_sbe_seeprom, i_target, is_master);
- if (!rc.ok())
- {
- FAPI_ERR("Error from proc_check_master_sbe_seeprom");
- break;
- }
- o_use_sbe_scan_service = !is_master;
- }
- // check for security state/attribute direction
- if (o_use_sbe_scan_service)
- {
- bool is_secure;
- FAPI_EXEC_HWP(rc, proc_check_security, i_target, is_secure);
- if (!rc.ok())
- {
- FAPI_ERR("Error from proc_check_security");
- break;
- }
- o_use_sbe_scan_service = is_secure;
-
- // force use of SBE scan service by attribute
- if (!o_use_sbe_scan_service)
- {
- fapi::ATTR_FORCE_USE_SBE_SLAVE_SCAN_SERVICE_Type force_use_sbe_attr;
- rc = FAPI_ATTR_GET(ATTR_FORCE_USE_SBE_SLAVE_SCAN_SERVICE, NULL, force_use_sbe_attr);
- if (!rc.ok())
- {
- FAPI_ERR("Error reading ATTR_FORCE_USE_SBE_SLAVE_SCAN_SERVICE");
- break;
- }
-
- o_use_sbe_scan_service = (force_use_sbe_attr == fapi::ENUM_ATTR_FORCE_USE_SBE_SLAVE_SCAN_SERVICE_TRUE);
- }
-
- // discontinue use of SBE scan service once trusted scan path is available
- if (o_use_sbe_scan_service)
- {
- fapi::ATTR_TRUSTED_SLAVE_SCAN_PATH_ACTIVE_Type trusted_slave_scan_path_active;
- rc = FAPI_ATTR_GET(ATTR_TRUSTED_SLAVE_SCAN_PATH_ACTIVE, NULL, trusted_slave_scan_path_active);
- if (!rc.ok())
- {
- FAPI_ERR("Error reading ATTR_TRUSTED_SLAVE_SCAN_PATH_ACTIVE");
- break;
- }
-
- o_use_sbe_scan_service = (trusted_slave_scan_path_active == fapi::ENUM_ATTR_TRUSTED_SLAVE_SCAN_PATH_ACTIVE_FALSE);
- }
- }
- } while(0);
-
- // mark function entry
- FAPI_DBG("End");
- return rc;
-}
-
-
-} // extern "C"
diff --git a/src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.H b/src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.H
deleted file mode 100644
index 69532ee63..000000000
--- a/src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.H
+++ /dev/null
@@ -1,80 +0,0 @@
-/* IBM_PROLOG_BEGIN_TAG */
-/* This is an automatically generated prolog. */
-/* */
-/* $Source: src/usr/hwpf/hwp/secure_boot/proc_use_sbe_scan_service.H $ */
-/* */
-/* OpenPOWER HostBoot Project */
-/* */
-/* Contributors Listed Below - COPYRIGHT 2015 */
-/* [+] International Business Machines Corp. */
-/* */
-/* */
-/* Licensed under the Apache License, Version 2.0 (the "License"); */
-/* you may not use this file except in compliance with the License. */
-/* You may obtain a copy of the License at */
-/* */
-/* http://www.apache.org/licenses/LICENSE-2.0 */
-/* */
-/* Unless required by applicable law or agreed to in writing, software */
-/* distributed under the License is distributed on an "AS IS" BASIS, */
-/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */
-/* implied. See the License for the specific language governing */
-/* permissions and limitations under the License. */
-/* */
-/* IBM_PROLOG_END_TAG */
-// $Id: proc_use_sbe_scan_service.H,v 1.1 2015/05/14 21:49:21 jmcgill Exp $
-// $Source: /afs/awd/projects/eclipz/KnowledgeBase/.cvsroot/eclipz/chips/p8/working/procedures/ipl/fapi/proc_use_sbe_scan_service.H,v $
-//------------------------------------------------------------------------------
-// *|
-// *! (C) Copyright International Business Machines Corp. 2015
-// *! All Rights Reserved -- Property of IBM
-// *! *** ***
-// *|
-// *! TITLE : proc_use_sbe_scan_service.H
-// *! DESCRIPTION : Shared routine used to determine use of SBE runtime scan
-// *! service
-// *!
-// *! OWNER NAME : Joe McGill Email: jmcgill@us.ibm.com
-// *!
-//------------------------------------------------------------------------------
-
-#ifndef _PROC_USE_SBE_SCAN_SERVICE_H_
-#define _PROC_USE_SBE_SCAN_SERVICE_H_
-
-//------------------------------------------------------------------------------
-// Includes
-//------------------------------------------------------------------------------
-#include <fapi.H>
-
-
-//------------------------------------------------------------------------------
-// Function prototypes
-//------------------------------------------------------------------------------
-
-// function pointer typedef definition for HWP call support
-typedef fapi::ReturnCode (*proc_use_sbe_scan_service_FP_t)(const fapi::Target &,
- bool &);
-
-
-//------------------------------------------------------------------------------
-// Function prototypes
-//------------------------------------------------------------------------------
-
-extern "C"
-{
-
-//------------------------------------------------------------------------------
-// function:
-// Use SBE runtime scan service?
-//
-// parameters: i_target => chip target
-// returns: FAPI_RC_SUCCESS if operation was successful, else error
-//------------------------------------------------------------------------------
-fapi::ReturnCode proc_use_sbe_scan_service(
- const fapi::Target& i_target,
- bool& o_use_sbe_scan_service);
-
-
-} // extern "C"
-
-#endif // _PROC_USE_SBE_SCAN_SERVICE_H_
OpenPOWER on IntegriCloud