summaryrefslogtreecommitdiffstats
path: root/src/hwpf/include/plat/plat_target.H
diff options
context:
space:
mode:
Diffstat (limited to 'src/hwpf/include/plat/plat_target.H')
-rw-r--r--src/hwpf/include/plat/plat_target.H60
1 files changed, 59 insertions, 1 deletions
diff --git a/src/hwpf/include/plat/plat_target.H b/src/hwpf/include/plat/plat_target.H
index 7f7ac99f..bf7bcad3 100644
--- a/src/hwpf/include/plat/plat_target.H
+++ b/src/hwpf/include/plat/plat_target.H
@@ -102,16 +102,74 @@ namespace fapi2
TargetType getFapiTargetType() const;
///
+ /// @brief Get the scom address overlay for this target
+ ///
+ /// @return Address overlay
+ ///
+ uint32_t getAddressOverlay() const
+ {
+ return (value & 0xFF000000);
+ }
+
+ ///
+ /// @brief Get the plat target type
+ ///
+ /// @return The plat target type as a fapi2::TargetType
+ ///
+ TargetType getTargetType() const
+ {
+ return static_cast<TargetType>(fields.type);
+ }
+
+ ///
/// @brief Get the instance number for this target
///
/// @return The instance number for this target
///
- inline uint32_t getTargetInstance() const
+ uint32_t getTargetInstance() const
{
return fields.type_target_num;
}
///
+ /// @brief Returns whether this target is functional
+ ///
+ /// @return true if Target is functional
+ ///
+ bool getFunctional() const
+ {
+ return fields.functional;
+ }
+
+ ///
+ /// @brief Set functional state of the Target
+ ///
+ /// @param [in] i_state Functional state to set
+ ///
+ void setFunctional(const bool &i_state)
+ {
+ fields.functional = i_state;
+ }
+
+ ///
+ /// @brief Returns whether this target is present
+ ///
+ /// @return true if Target is present
+ ///
+ bool getPresent() const
+ {
+ return fields.present;
+ }
+
+ ///
+ /// @brief Set Target as present
+ ///
+ void setPresent()
+ {
+ fields.present = true;
+ }
+
+ ///
/// @brief Get this target's children
///
/// @param [in] i_parentType fapi2 type of the parent
OpenPOWER on IntegriCloud