diff options
Diffstat (limited to 'src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/plug_rules/exp_plug_rules.H')
-rw-r--r-- | src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/plug_rules/exp_plug_rules.H | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/plug_rules/exp_plug_rules.H b/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/plug_rules/exp_plug_rules.H index a9230f765..2fbc0d7df 100644 --- a/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/plug_rules/exp_plug_rules.H +++ b/src/import/chips/ocmb/explorer/procedures/hwp/memory/lib/plug_rules/exp_plug_rules.H @@ -22,3 +22,61 @@ /* permissions and limitations under the License. */ /* */ /* IBM_PROLOG_END_TAG */ + +/// +/// @file exp_plug_rules.H +/// @brief Plug rules enforcement for explorer +/// +// *HWP HWP Owner: Mark Pizzutillo <Mark.Pizzutillo@ibm.com> +// *HWP HWP Backup: Stephen Glancy <sglancy@us.ibm.com> +// *HWP Team: Memory +// *HWP Level: 2 +// *HWP Consumed by: FSP:HB + +#ifndef _EXP_PLUG_RULES_H_ +#define _EXP_PLUG_RULES_H_ + +#include <fapi2.H> + +namespace mss +{ +namespace exp +{ +namespace plug_rule +{ + +/// +/// @brief Determine enterprise mode from given attribute/fuse values +/// +/// @param[in] i_target OCMB chip target +/// @param[in] i_enterprise_fuse enterprise as determined from fuse +/// @param[in] i_enterprise_policy enterprise policy system attribute value +/// @param[in] i_non_enterprise_override override attribute value +/// @param[out] o_is_enterprise_mode resulting state for enterprise mode +/// @return fapi2::ReturnCode FAPI2_RC_SUCCESS iff success, else error code +/// @note this helper function exists for unit testing purposes +/// +fapi2::ReturnCode enterprise_mode_helper( + const fapi2::Target<fapi2::TARGET_TYPE_OCMB_CHIP>& i_target, + const bool i_enterprise_fuse, + const uint8_t i_enterprise_policy, + const uint8_t i_non_enterprise_override, + bool& o_is_enterprise_mode); + +/// +/// @brief Gets whether the OCMB will be configred to enterprise mode, will assert out if policy/override do not agree +/// @param[in] i_target OCMB target on which to operate +/// @param[in] i_enterprise_fuse enterprise as determined from fuse +/// @param[out] o_is_enterprise_mode true if the part is in enterprise mode +/// @return fapi2::ReturnCode - FAPI2_RC_SUCCESS iff get is OK +/// +fapi2::ReturnCode enterprise_mode( + const fapi2::Target<fapi2::TARGET_TYPE_OCMB_CHIP>& i_target, + const bool i_enterprise_fuse, + bool& o_is_enterprise_mode ); + +} // plug_rule +} // exp +} // mss + +#endif |