From d6dcd0125e002508ea665a5b71eb2019a0274c91 Mon Sep 17 00:00:00 2001 From: Santosh Puranik Date: Tue, 13 Sep 2016 11:31:46 -0500 Subject: FAPI Plat Cleanup - III -- Move completely to using FAPI from src/import Change-Id: Ifd27a900fea45ef0e7d6bd4a62192e50812b99ac Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/29581 Tested-by: Jenkins Server Reviewed-by: Sachin Gupta Tested-by: FSP CI Jenkins Reviewed-by: Shakeeb A. Pasha B K Reviewed-by: Santosh S. Puranik --- src/hwpf/src/plat/plat_attribute_service.H | 9 +++++---- src/hwpf/src/plat/target.C | 23 +++++++++++------------ 2 files changed, 16 insertions(+), 16 deletions(-) (limited to 'src/hwpf/src') diff --git a/src/hwpf/src/plat/plat_attribute_service.H b/src/hwpf/src/plat/plat_attribute_service.H index 9e2a26a2..2decbed4 100644 --- a/src/hwpf/src/plat/plat_attribute_service.H +++ b/src/hwpf/src/plat/plat_attribute_service.H @@ -6,6 +6,7 @@ /* OpenPOWER sbe Project */ /* */ /* Contributors Listed Below - COPYRIGHT 2015,2016 */ +/* [+] International Business Machines Corp. */ /* */ /* */ /* Licensed under the Apache License, Version 2.0 (the "License"); */ @@ -56,12 +57,12 @@ /* global get uint8_t 1D array macro */ #define PLAT_ATTR_GET_UINT8_1D_ARRAY(ID, PTARGET, VAL) \ - _getAttributeArrayShort(ID##_TargetTypes), ID> \ + _getAttributeArrayShort(ID##TargetType), ID> \ (ID, PTARGET, VAL) /* global set uint8_t 1D array macro */ #define PLAT_ATTR_SET_UINT8_1D_ARRAY(ID, PTARGET, VAL) \ - _setAttributeArrayShort(ID##_TargetTypes), ID> \ + _setAttributeArrayShort(ID##TargetType), ID> \ (ID, PTARGET, VAL) /* global get uint8_t 2D array macro */ @@ -144,12 +145,12 @@ /* global get int macro (uint8_t, 16, 32 and 64) */ #define PLAT_ATTR_GET_GLOBAL_INT(ID, PTARGET, VAL) \ - _get(ID##_TargetTypes), ID> \ + _get(ID##_TargetType), ID> \ (ID, PTARGET, VAL) /* global set int macro (uint8_t, 16, 32 and 64) */ #define PLAT_ATTR_SET_GLOBAL_INT(ID, PTARGET, VAL) \ - _set(ID##_TargetTypes), ID> \ + _set(ID##_TargetType), ID> \ (ID, PTARGET, VAL) diff --git a/src/hwpf/src/plat/target.C b/src/hwpf/src/plat/target.C index 9600140a..4249c6ec 100644 --- a/src/hwpf/src/plat/target.C +++ b/src/hwpf/src/plat/target.C @@ -318,18 +318,17 @@ namespace fapi2 if (b_present) { - i_chiplet_target.setPresent(); - i_chiplet_target.setFunctional(true); + static_cast((i_chiplet_target.operator()())).setPresent(); + static_cast((i_chiplet_target.operator()())).setFunctional(true); } else { - FAPI_DBG("Perv target NOT present (nor functional): chiplet_number = %d", - i_chiplet_target.getChipletNumber()); + FAPI_DBG("Perv target NOT present (nor functional): chiplet_number = %d", i_chiplet_target.getChipletNumber()); } FAPI_DBG("Target present = %u, Target functional = %u", - i_chiplet_target.getPresent(), - i_chiplet_target.getFunctional()); + static_cast(i_chiplet_target.get()).getPresent(), + static_cast(i_chiplet_target.get()).getFunctional()); fapi_try_exit: return fapi2::current_err; @@ -490,8 +489,8 @@ fapi_try_exit: if(0 == l_eqAttrPg) { - target_name.setPresent(); - target_name.setFunctional(true); + static_cast(target_name.operator ()()).setPresent(); + static_cast(target_name.operator ()()).setFunctional(true); } G_vec_targets.at(l_beginning_offset+i) = revle32((fapi2::plat_target_handle_t)(target_name.get())); } @@ -525,8 +524,8 @@ fapi_try_exit: if(0 == l_attrPg) { - target_name.setPresent(); - target_name.setFunctional(true); + static_cast(target_name.operator ()()).setPresent(); + static_cast(target_name.operator ()()).setFunctional(true); } G_vec_targets.at(l_beginning_offset+i) = revle32((fapi2::plat_target_handle_t)(target_name.get())); @@ -572,7 +571,7 @@ fapi_try_exit: FAPI_DBG("Making %d'th EQ non-functional", l_idx); // EQ chiplet l_idx is to be marked non-functional fapi2::Target l_target = G_vec_targets.at(l_idx + EQ_TARGET_OFFSET); - l_target.setFunctional(false); + static_cast(l_target.operator ()()).setFunctional(false); G_vec_targets.at(l_idx + EQ_TARGET_OFFSET) = l_target.get(); } } @@ -584,7 +583,7 @@ fapi_try_exit: FAPI_DBG("Making %d'th EC non-functional", l_idx); // EC chiplet l_idx is to be marked non-functional fapi2::Target l_target = G_vec_targets.at(l_idx + CORE_TARGET_OFFSET); - l_target.setFunctional(false); + static_cast(l_target.operator ()()).setFunctional(false); G_vec_targets.at(l_idx + CORE_TARGET_OFFSET) = l_target.get(); } else -- cgit v1.2.1