Changeset 2fcea4c in rtems for cpukit/posix


Ignore:
Timestamp:
Oct 17, 2017, 8:06:08 AM (2 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
2be22d4
Parents:
91ce012c
git-author:
Sebastian Huber <sebastian.huber@…> (10/17/17 08:06:08)
git-committer:
Sebastian Huber <sebastian.huber@…> (10/17/17 08:12:10)
Message:

posix: Fix _POSIX_Threads_Create_extension()

The thread POSIX API control must be fully initialized in
_POSIX_Threads_Create_extension(), otherwise a pthread_setschedparam()
is broken for all threads not created with pthread_create().

Location:
cpukit/posix/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • cpukit/posix/src/pthread.c

    r91ce012c r2fcea4c  
    152152  _Watchdog_Preinitialize( &api->Sporadic.Timer, _Per_CPU_Get_by_index( 0 ) );
    153153  _Watchdog_Initialize( &api->Sporadic.Timer, _POSIX_Threads_Sporadic_timer );
     154  _Priority_Node_set_inactive( &api->Sporadic.Low_priority );
    154155
    155156  return true;
  • cpukit/posix/src/pthreadcreate.c

    r91ce012c r2fcea4c  
    243243  api->schedpolicy = the_attr->schedpolicy;
    244244  api->schedparam = the_attr->schedparam;
    245   _Priority_Node_initialize( &api->Sporadic.Low_priority, core_low_prio );
    246   _Priority_Node_set_inactive( &api->Sporadic.Low_priority );
     245  _Priority_Node_set_priority( &api->Sporadic.Low_priority, core_low_prio );
    247246
    248247  if ( schedpolicy == SCHED_SPORADIC ) {
Note: See TracChangeset for help on using the changeset viewer.