diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2014-04-04 13:58:26 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2014-04-07 14:51:31 +0200 |
commit | e785fbaae519e096e636e1dcea5a739dfead8c46 (patch) | |
tree | a342b5128baa070ea05663afac1f358298edb2f1 /cpukit/posix/src | |
parent | score: Delete _Thread_Maximum_extensions (diff) | |
download | rtems-e785fbaae519e096e636e1dcea5a739dfead8c46.tar.bz2 |
score: Delete _Thread_Ticks_per_timeslice
Use the Configuration instead.
Diffstat (limited to 'cpukit/posix/src')
-rw-r--r-- | cpukit/posix/src/pthreadsetschedparam.c | 4 | ||||
-rw-r--r-- | cpukit/posix/src/sched_rr_get_interval.c | 9 |
2 files changed, 9 insertions, 4 deletions
diff --git a/cpukit/posix/src/pthreadsetschedparam.c b/cpukit/posix/src/pthreadsetschedparam.c index 4b62179553..d5d0a5ba8a 100644 --- a/cpukit/posix/src/pthreadsetschedparam.c +++ b/cpukit/posix/src/pthreadsetschedparam.c @@ -30,6 +30,7 @@ #include <rtems/posix/time.h> #include <rtems/score/threadimpl.h> #include <rtems/score/watchdogimpl.h> +#include <rtems/config.h> int pthread_setschedparam( pthread_t thread, @@ -83,7 +84,8 @@ int pthread_setschedparam( case SCHED_OTHER: case SCHED_FIFO: case SCHED_RR: - the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice; + the_thread->cpu_time_budget = + rtems_configuration_get_ticks_per_timeslice(); the_thread->real_priority = _POSIX_Priority_To_core( api->schedparam.sched_priority ); diff --git a/cpukit/posix/src/sched_rr_get_interval.c b/cpukit/posix/src/sched_rr_get_interval.c index 060cea0f58..1cb78eaf74 100644 --- a/cpukit/posix/src/sched_rr_get_interval.c +++ b/cpukit/posix/src/sched_rr_get_interval.c @@ -24,9 +24,8 @@ #include <sched.h> #include <errno.h> -#include <rtems/system.h> -#include <rtems/score/threadimpl.h> #include <rtems/score/timespec.h> +#include <rtems/config.h> #include <rtems/seterr.h> int sched_rr_get_interval( @@ -44,6 +43,10 @@ int sched_rr_get_interval( if ( !interval ) rtems_set_errno_and_return_minus_one( EINVAL ); - _Timespec_From_ticks( _Thread_Ticks_per_timeslice, interval ); + _Timespec_From_ticks( + rtems_configuration_get_ticks_per_timeslice(), + interval + ); + return 0; } |