Changeset 4ea97d24 in rtems for cpukit/sapi


Ignore:
Timestamp:
Nov 19, 2013, 3:21:54 PM (6 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
bb81e04
Parents:
833dd90
git-author:
Sebastian Huber <sebastian.huber@…> (11/19/13 15:21:54)
git-committer:
Sebastian Huber <sebastian.huber@…> (11/21/13 11:58:46)
Message:

score/rbtree: Remove "unprotected" from API

Location:
cpukit/sapi
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • cpukit/sapi/include/rtems/rbtree.h

    r833dd90 r4ea97d24  
    2828
    2929/**
     30 * @defgroup ClassicRBTrees Red-Black Trees
     31 *
     32 * @ingroup ClassicRTEMS
     33 *
     34 * @brief A Red-Black Tree container.
     35 *
     36 * The red-black tree container offers no internal protection against
     37 * concurrent access.  The user must ensure that at most one thread at once can
     38 * access a red-black tree instance.
     39 *
     40 * @{
     41 */
     42
     43/**
    3044 * @typedef rtems_rbtree_node
    3145 *
     
    300314
    301315/**
    302  * @copydoc _RBTree_Find_unprotected()
    303  */
    304 RTEMS_INLINE_ROUTINE rtems_rbtree_node* rtems_rbtree_find_unprotected(
     316 * @copydoc _RBTree_Find()
     317 */
     318RTEMS_INLINE_ROUTINE rtems_rbtree_node* rtems_rbtree_find(
    305319  const rtems_rbtree_control *the_rbtree,
    306320  const rtems_rbtree_node *the_node
    307321)
    308322{
    309   return _RBTree_Find_unprotected( the_rbtree, the_node );
    310 }
    311 
    312 /**
    313  * @copydoc _RBTree_Predecessor_unprotected()
    314  */
    315 RTEMS_INLINE_ROUTINE rtems_rbtree_node* rtems_rbtree_predecessor_unprotected(
     323  return _RBTree_Find( the_rbtree, the_node );
     324}
     325
     326/**
     327 * @copydoc _RBTree_Predecessor()
     328 */
     329RTEMS_INLINE_ROUTINE rtems_rbtree_node* rtems_rbtree_predecessor(
    316330  const rtems_rbtree_node *node
    317331)
    318332{
    319   return _RBTree_Predecessor_unprotected( node );
    320 }
    321 
    322 /**
    323  * @copydoc _RBTree_Successor_unprotected()
    324  */
    325 RTEMS_INLINE_ROUTINE rtems_rbtree_node* rtems_rbtree_successor_unprotected(
     333  return _RBTree_Predecessor( node );
     334}
     335
     336/**
     337 * @copydoc _RBTree_Successor()
     338 */
     339RTEMS_INLINE_ROUTINE rtems_rbtree_node* rtems_rbtree_successor(
    326340  const rtems_rbtree_node *node
    327341)
    328342{
    329   return _RBTree_Successor_unprotected( node );
    330 }
    331 
    332 /**
    333  * @copydoc _RBTree_Extract_unprotected()
    334  */
    335 RTEMS_INLINE_ROUTINE void rtems_rbtree_extract_unprotected(
     343  return _RBTree_Successor( node );
     344}
     345
     346/**
     347 * @copydoc _RBTree_Extract()
     348 */
     349RTEMS_INLINE_ROUTINE void rtems_rbtree_extract(
    336350  rtems_rbtree_control *the_rbtree,
    337351  rtems_rbtree_node *the_node
    338352)
    339353{
    340   _RBTree_Extract_unprotected( the_rbtree, the_node );
     354  _RBTree_Extract( the_rbtree, the_node );
    341355}
    342356
     
    348362 */
    349363
    350 RTEMS_INLINE_ROUTINE rtems_rbtree_node *rtems_rbtree_get_min_unprotected(
     364RTEMS_INLINE_ROUTINE rtems_rbtree_node *rtems_rbtree_get_min(
    351365  rtems_rbtree_control *the_rbtree
    352366)
    353367{
    354   return _RBTree_Get_unprotected( the_rbtree, RBT_LEFT );
     368  return _RBTree_Get( the_rbtree, RBT_LEFT );
    355369}
    356370
     
    362376 */
    363377
    364 RTEMS_INLINE_ROUTINE rtems_rbtree_node *rtems_rbtree_get_max_unprotected(
     378RTEMS_INLINE_ROUTINE rtems_rbtree_node *rtems_rbtree_get_max(
    365379  rtems_rbtree_control *the_rbtree
    366380)
    367381{
    368   return _RBTree_Get_unprotected( the_rbtree, RBT_RIGHT );
     382  return _RBTree_Get( the_rbtree, RBT_RIGHT );
    369383}
    370384
     
    398412
    399413/**
    400  * @copydoc _RBTree_Find_header_unprotected()
    401  */
    402 RTEMS_INLINE_ROUTINE rtems_rbtree_control *rtems_rbtree_find_header_unprotected(
     414 * @copydoc _RBTree_Find_header()
     415 */
     416RTEMS_INLINE_ROUTINE rtems_rbtree_control *rtems_rbtree_find_header(
    403417  rtems_rbtree_node *the_node
    404418)
    405419{
    406   return _RBTree_Find_header_unprotected( the_node );
    407 }
    408 
    409 /**
    410  * @copydoc _RBTree_Insert_unprotected()
    411  */
    412 RTEMS_INLINE_ROUTINE rtems_rbtree_node *rtems_rbtree_insert_unprotected(
     420  return _RBTree_Find_header( the_node );
     421}
     422
     423/**
     424 * @copydoc _RBTree_Insert()
     425 */
     426RTEMS_INLINE_ROUTINE rtems_rbtree_node *rtems_rbtree_insert(
    413427  rtems_rbtree_control *the_rbtree,
    414428  rtems_rbtree_node *the_node
    415429)
    416430{
    417   return _RBTree_Insert_unprotected( the_rbtree, the_node );
     431  return _RBTree_Insert( the_rbtree, the_node );
    418432}
    419433
     
    428442}
    429443
     444/** @} */
     445
    430446#ifdef __cplusplus
    431447}
  • cpukit/sapi/src/rbheap.c

    r833dd90 r4ea97d24  
    8181)
    8282{
    83   _RBTree_Insert_unprotected(tree, &chunk->tree_node);
     83  _RBTree_Insert(tree, &chunk->tree_node);
    8484}
    8585
     
    199199
    200200  return rtems_rbheap_chunk_of_node(
    201     _RBTree_Find_unprotected(chunk_tree, &chunk.tree_node)
     201    _RBTree_Find(chunk_tree, &chunk.tree_node)
    202202  );
    203203}
     
    209209{
    210210  return rtems_rbheap_chunk_of_node(
    211     _RBTree_Next_unprotected(&chunk->tree_node, dir)
     211    _RBTree_Next(&chunk->tree_node, dir)
    212212  );
    213213}
     
    231231    rtems_chain_extract_unprotected(&b->chain_node);
    232232    add_to_chain(free_chain, b);
    233     _RBTree_Extract_unprotected(chunk_tree, &b->tree_node);
     233    _RBTree_Extract(chunk_tree, &b->tree_node);
    234234  }
    235235}
Note: See TracChangeset for help on using the changeset viewer.