summaryrefslogtreecommitdiffstats
path: root/cpukit/sapi/inline/rtems
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2012-12-21 09:50:15 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2012-12-21 15:40:27 +0100
commitcbd07e4ce0ede36bacf6920bd594579e931b1bdd (patch)
tree716aba4b883d92fe7a8aab8338dc783ba04d812d /cpukit/sapi/inline/rtems
parentbsp/gen83xx: Add GPR_1 to register map (diff)
downloadrtems-cbd07e4ce0ede36bacf6920bd594579e931b1bdd.tar.bz2
score: Add rtems_chain_node_count_unprotected()
Diffstat (limited to 'cpukit/sapi/inline/rtems')
-rw-r--r--cpukit/sapi/inline/rtems/chain.inl17
1 files changed, 17 insertions, 0 deletions
diff --git a/cpukit/sapi/inline/rtems/chain.inl b/cpukit/sapi/inline/rtems/chain.inl
index d7f7f7152d..a1bfc2f32e 100644
--- a/cpukit/sapi/inline/rtems/chain.inl
+++ b/cpukit/sapi/inline/rtems/chain.inl
@@ -645,6 +645,23 @@ RTEMS_INLINE_ROUTINE bool rtems_chain_get_with_empty_check(
return _Chain_Get_with_empty_check( chain, node );
}
+/**
+ * @brief Returns the node count of the chain.
+ *
+ * @param[in] chain The chain.
+ *
+ * @note It does NOT disable interrupts to ensure the atomicity of the
+ * operation.
+ *
+ * @return The node count of the chain.
+ */
+RTEMS_INLINE_ROUTINE size_t rtems_chain_node_count_unprotected(
+ const rtems_chain_control *chain
+)
+{
+ return _Chain_Node_count_unprotected( chain );
+}
+
/** @} */
#endif