diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2018-11-25 20:26:02 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2018-12-07 14:22:02 +0100 |
commit | f70079ca20b11da6e481ddfeab4516545ec71cbd (patch) | |
tree | 1e0ed015de156f47708ca69b37b05c2eb9edabd4 /cpukit/score/src/objectextendinformation.c | |
parent | score: Remove Objects_Information::maximum (diff) | |
download | rtems-f70079ca20b11da6e481ddfeab4516545ec71cbd.tar.bz2 |
score: Remove Objects_Information::the_api
Remove Objects_Information::the_class. This information is already
contained in Objects_Information::maximum_id.
Update #3621.
Diffstat (limited to 'cpukit/score/src/objectextendinformation.c')
-rw-r--r-- | cpukit/score/src/objectextendinformation.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/cpukit/score/src/objectextendinformation.c b/cpukit/score/src/objectextendinformation.c index 57ce6737ec..4e55bbc636 100644 --- a/cpukit/score/src/objectextendinformation.c +++ b/cpukit/score/src/objectextendinformation.c @@ -54,12 +54,14 @@ void _Objects_Extend_information( size_t object_block_size; Objects_Control *new_object_block; bool do_extend; + Objects_Id api_class_and_node; _Assert( _Objects_Allocator_is_owner() || !_System_state_Is_up( _System_state_Get() ) ); + api_class_and_node = information->maximum_id & ~OBJECTS_INDEX_MASK; old_maximum = _Objects_Get_maximum_index( information ); /* @@ -218,12 +220,8 @@ void _Objects_Extend_information( information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->local_table = local_table; - information->maximum_id = _Objects_Build_id( - information->the_api, - information->the_class, - _Objects_Local_node, - new_maximum - ); + information->maximum_id = api_class_and_node + | (new_maximum << OBJECTS_INDEX_START_BIT); _ISR_lock_ISR_enable( &lock_context ); @@ -244,12 +242,8 @@ void _Objects_Extend_information( */ the_object = new_object_block; for ( index = index_base ; index < index_end ; ++index ) { - the_object->id = _Objects_Build_id( - information->the_api, - information->the_class, - _Objects_Local_node, - index + OBJECTS_INDEX_MINIMUM - ); + the_object->id = api_class_and_node + | ( ( index + OBJECTS_INDEX_MINIMUM ) << OBJECTS_INDEX_START_BIT ); _Chain_Initialize_node( &the_object->Node ); _Chain_Append_unprotected( &information->Inactive, &the_object->Node ); |