Changeset 3bacb250 in rtems


Ignore:
Timestamp:
Apr 3, 2010, 5:55:59 AM (9 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.10, 4.11, master
Children:
e24760ae
Parents:
394ac3c
Message:

Reflect POSIX sched_parm changes.

Location:
cpukit/posix/src
Files:
3 edited

Legend:

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

    r394ac3c r3bacb250  
    5050
    5151  if ( policy == SCHED_SPORADIC ) {
    52     if ( (param->ss_replenish_period.tv_sec == 0) &&
    53          (param->ss_replenish_period.tv_nsec == 0) )
     52    if ( (param->sched_ss_repl_period.tv_sec == 0) &&
     53         (param->sched_ss_repl_period.tv_nsec == 0) )
    5454      return EINVAL;
    5555
    56     if ( (param->ss_initial_budget.tv_sec == 0) &&
    57          (param->ss_initial_budget.tv_nsec == 0) )
     56    if ( (param->sched_ss_init_budget.tv_sec == 0) &&
     57         (param->sched_ss_init_budget.tv_nsec == 0) )
    5858      return EINVAL;
    5959
    60     if ( _Timespec_To_ticks( &param->ss_replenish_period ) <
    61          _Timespec_To_ticks( &param->ss_initial_budget ) )
     60    if ( _Timespec_To_ticks( &param->sched_ss_repl_period ) <
     61         _Timespec_To_ticks( &param->sched_ss_init_budget ) )
    6262      return EINVAL;
    6363
    64     if ( !_POSIX_Priority_Is_valid( param->ss_low_priority ) )
     64    if ( !_POSIX_Priority_Is_valid( param->sched_ss_low_priority ) )
    6565      return EINVAL;
    6666
  • cpukit/posix/src/pthread.c

    r394ac3c r3bacb250  
    11/*
    2  *  COPYRIGHT (c) 1989-2009.
     2 *  COPYRIGHT (c) 1989-2010.
    33 *  On-Line Applications Research Corporation (OAR).
    44 *
     
    4949  {                           /* schedparam */
    5050    2,                        /* sched_priority */
    51     0,                        /* ss_low_priority */
    52     { 0L, 0 },                /* ss_replenish_period */
    53     { 0L, 0 }                 /* ss_initial_budget */
     51    0,                        /* sched_ss_low_priority */
     52    { 0L, 0 },                /* sched_ss_repl_period */
     53    { 0L, 0 }                 /* sched_ss_init_budget */
    5454  },
    5555  PTHREAD_CREATE_JOINABLE,    /* detachstate */
     
    7575
    7676  /* ticks is guaranteed to be at least one */
    77   ticks = _Timespec_To_ticks( &api->schedparam.ss_initial_budget );
     77  ticks = _Timespec_To_ticks( &api->schedparam.sched_ss_init_budget );
    7878
    7979  the_thread->cpu_time_budget = ticks;
    8080
    81   new_priority = _POSIX_Priority_To_core( api->ss_high_priority );
     81  new_priority = _POSIX_Priority_To_core( api->schedparam.sched_priority );
    8282  the_thread->real_priority = new_priority;
    8383
     
    102102
    103103  /* ticks is guaranteed to be at least one */
    104   ticks = _Timespec_To_ticks( &api->schedparam.ss_replenish_period );
     104  ticks = _Timespec_To_ticks( &api->schedparam.sched_ss_repl_period );
    105105
    106106  _Watchdog_Insert_ticks( &api->Sporadic_timer, ticks );
     
    125125  the_thread->cpu_time_budget = 0xFFFFFFFF; /* XXX should be based on MAX_U32 */
    126126
    127   new_priority = _POSIX_Priority_To_core( api->schedparam.ss_low_priority );
     127  new_priority = _POSIX_Priority_To_core(api->schedparam.sched_ss_low_priority);
    128128  the_thread->real_priority = new_priority;
    129129
     
    138138    /*
    139139     *  Make sure we are actually lowering it. If they have lowered it
    140      *  to logically lower than ss_low_priority, then we do not want to
     140     *  to logically lower than sched_ss_low_priority, then we do not want to
    141141     *  change it.
    142142     */
  • cpukit/posix/src/pthreadcreate.c

    r394ac3c r3bacb250  
    227227    _Watchdog_Insert_ticks(
    228228      &api->Sporadic_timer,
    229       _Timespec_To_ticks( &api->schedparam.ss_replenish_period )
     229      _Timespec_To_ticks( &api->schedparam.sched_ss_repl_period )
    230230    );
    231231  }
Note: See TracChangeset for help on using the changeset viewer.