summaryrefslogtreecommitdiffstats
path: root/src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H
diff options
context:
space:
mode:
authorLouis Stermole <stermole@us.ibm.com>2016-09-14 07:39:10 -0500
committerChristian R. Geddes <crgeddes@us.ibm.com>2016-10-04 18:48:09 -0400
commit6a41be7a1e83d4ede3116b926719caa1037992b9 (patch)
treece085832d7d8683bd7cff767200e8257d4d519cc /src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H
parente1e8610960d9b5124a656b662144ff6b76631e85 (diff)
downloadtalos-hostboot-6a41be7a1e83d4ede3116b926719caa1037992b9.tar.gz
talos-hostboot-6a41be7a1e83d4ede3116b926719caa1037992b9.zip
Add DIMM to PHY mapping to access_delay_regs
Add mss::is_odd util function Change-Id: Ia549f538e139e5431531e33f76d04ab4b64cf466 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/29889 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com> Reviewed-by: Christian R. Geddes <crgeddes@us.ibm.com> Reviewed-by: STEPHEN GLANCY <sglancy@us.ibm.com> Reviewed-by: Brian R. Silver <bsilver@us.ibm.com> Reviewed-by: Jennifer A. Stofer <stofer@us.ibm.com> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/30582 Reviewed-by: Hostboot Team <hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Diffstat (limited to 'src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H')
-rw-r--r--src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H b/src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H
index f025b19df..61a04a680 100644
--- a/src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H
+++ b/src/import/chips/p9/procedures/hwp/memory/lib/utils/num.H
@@ -22,3 +22,34 @@
/* permissions and limitations under the License. */
/* */
/* IBM_PROLOG_END_TAG */
+
+///
+/// @file num.H
+/// @brief Miscellaneous number checking functions
+///
+// *HWP HWP Owner: Louis Stermole <stermole@us.ibm.com>
+// *HWP HWP Backup: Brian Silver <bsilver@us.ibm.com>
+// *HWP Team: Memory
+// *HWP Level: 2
+// *HWP Consumed by: HB:FSP
+
+#ifndef _MSS_NUM_H_
+#define _MSS_NUM_H_
+
+namespace mss
+{
+
+///
+/// @brief Return whether or not a number is odd
+/// @param[in] i_number the number to check
+/// @return true if i_number is odd
+///
+template< typename T >
+constexpr bool is_odd(const T i_number)
+{
+ return (i_number & 0x1);
+}
+
+
+}
+#endif
OpenPOWER on IntegriCloud