Changeset e785fbaa in rtems


Ignore:
Timestamp:
Apr 4, 2014, 11:58:26 AM (6 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
57c2985
Parents:
47445846
git-author:
Sebastian Huber <sebastian.huber@…> (04/04/14 11:58:26)
git-committer:
Sebastian Huber <sebastian.huber@…> (04/07/14 12:51:31)
Message:

score: Delete _Thread_Ticks_per_timeslice

Use the Configuration instead.

Files:
9 edited

Legend:

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

    r47445846 re785fbaa  
    3131#include <rtems/score/threadimpl.h>
    3232#include <rtems/score/watchdogimpl.h>
     33#include <rtems/config.h>
    3334
    3435int pthread_setschedparam(
     
    8485        case SCHED_FIFO:
    8586        case SCHED_RR:
    86           the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
     87          the_thread->cpu_time_budget =
     88            rtems_configuration_get_ticks_per_timeslice();
    8789
    8890          the_thread->real_priority =
  • cpukit/posix/src/sched_rr_get_interval.c

    r47445846 re785fbaa  
    2525#include <errno.h>
    2626
    27 #include <rtems/system.h>
    28 #include <rtems/score/threadimpl.h>
    2927#include <rtems/score/timespec.h>
     28#include <rtems/config.h>
    3029#include <rtems/seterr.h>
    3130
     
    4544    rtems_set_errno_and_return_minus_one( EINVAL );
    4645
    47   _Timespec_From_ticks( _Thread_Ticks_per_timeslice, interval );
     46  _Timespec_From_ticks(
     47    rtems_configuration_get_ticks_per_timeslice(),
     48    interval
     49  );
     50
    4851  return 0;
    4952}
  • cpukit/rtems/src/taskmode.c

    r47445846 re785fbaa  
    106106    if ( _Modes_Is_timeslice(mode_set) ) {
    107107      executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
    108       executing->cpu_time_budget  = _Thread_Ticks_per_timeslice;
     108      executing->cpu_time_budget =
     109        rtems_configuration_get_ticks_per_timeslice();
    109110    } else
    110111      executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_NONE;
  • cpukit/score/include/rtems/score/threadimpl.h

    r47445846 re785fbaa  
    5757 */
    5858SCORE_EXTERN Objects_Information _Thread_Internal_information;
    59 
    60 /**
    61  *  The following is used to manage the length of a timeslice quantum.
    62  */
    63 SCORE_EXTERN uint32_t   _Thread_Ticks_per_timeslice;
    6459
    6560/**
  • cpukit/score/src/schedulerdefaulttick.c

    r47445846 re785fbaa  
    2323#include <rtems/score/threadimpl.h>
    2424#include <rtems/score/smp.h>
     25#include <rtems/config.h>
    2526
    2627static void _Scheduler_default_Tick_for_executing(
     
    7071         */
    7172        _Scheduler_Yield( scheduler, executing );
    72         executing->cpu_time_budget = _Thread_Ticks_per_timeslice;
     73        executing->cpu_time_budget =
     74          rtems_configuration_get_ticks_per_timeslice();
    7375      }
    7476      break;
  • cpukit/score/src/thread.c

    r47445846 re785fbaa  
    5151#endif
    5252
    53   _Thread_Ticks_per_timeslice  = ticks_per_timeslice;
    54 
    5553  #if defined(RTEMS_MULTIPROCESSING)
    5654    _Thread_MP_Handler_initialization( maximum_proxies );
  • cpukit/score/src/threaddispatch.c

    r47445846 re785fbaa  
    2929#include <rtems/score/userextimpl.h>
    3030#include <rtems/score/wkspace.h>
     31#include <rtems/config.h>
    3132
    3233static Thread_Action *_Thread_Get_post_switch_action(
     
    122123#endif
    123124    if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
    124       heir->cpu_time_budget = _Thread_Ticks_per_timeslice;
     125      heir->cpu_time_budget = rtems_configuration_get_ticks_per_timeslice();
    125126
    126127#if !defined( RTEMS_SMP )
  • cpukit/score/src/threadinitialize.c

    r47445846 re785fbaa  
    190190    #if defined(RTEMS_SCORE_THREAD_ENABLE_EXHAUST_TIMESLICE)
    191191      case THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE:
    192         the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
     192        the_thread->cpu_time_budget =
     193          rtems_configuration_get_ticks_per_timeslice();
    193194        break;
    194195    #endif
  • testsuites/sptests/spsize/size.c

    r47445846 re785fbaa  
    386386
    387387/*thread.h*/    (sizeof _Thread_Dispatch_disable_level)   +
    388                 (sizeof _Thread_Ticks_per_timeslice)      +
    389388                (sizeof _Thread_Executing)                +
    390389                (sizeof _Thread_Heir)                     +
Note: See TracChangeset for help on using the changeset viewer.