* sapi/include/confdefs.h, score/include/rtems/score/scheduler.h,
	score/inline/rtems/score/scheduler.inl,
	score/inline/rtems/score/schedulerpriority.inl,
	score/src/schedulerpriority.c,
	score/src/schedulerprioritythreadschedulerallocate.c,
	score/src/schedulerprioritythreadschedulerfree.c,
	score/src/schedulerprioritythreadschedulerupdate.c,
	score/src/schedulerpriorityyield.c: Added attribute unused.  Renamed
	types and fields to follow the Score naming conventions.
This commit is contained in:
Sebastian Huber
2010-11-25 13:24:26 +00:00
parent 215f4014e6
commit 5c4e0c5947
10 changed files with 45 additions and 34 deletions
+12
View File
@@ -1,3 +1,15 @@
2010-11-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
* sapi/include/confdefs.h, score/include/rtems/score/scheduler.h,
score/inline/rtems/score/scheduler.inl,
score/inline/rtems/score/schedulerpriority.inl,
score/src/schedulerpriority.c,
score/src/schedulerprioritythreadschedulerallocate.c,
score/src/schedulerprioritythreadschedulerfree.c,
score/src/schedulerprioritythreadschedulerupdate.c,
score/src/schedulerpriorityyield.c: Added attribute unused. Renamed
types and fields to follow the Score naming conventions.
2010-11-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
* score/include/rtems/score/scheduler.h,
+1 -1
View File
@@ -617,7 +617,7 @@ rtems_fs_init_functions_t rtems_fs_init_helper =
#ifdef CONFIGURE_INIT
/* the table of available schedulers. */
const Scheduler_Table_t _Scheduler_Table[] = {
const Scheduler_Table_entry _Scheduler_Table[] = {
#if defined(CONFIGURE_SCHEDULER_USER) && \
defined(CONFIGURE_SCHEDULER_ENTRY_USER)
CONFIGURE_SCHEDULER_ENTRY_USER,
+8 -9
View File
@@ -38,7 +38,7 @@ extern "C" {
/*
* These defines are used to set the scheduler_policy value. The values
* must correspond directly with the order of the fields in the scheduler
* table (Scheduler_Table_t), because the Configuration.scheduler_policy
* table (Scheduler_Table_entry), because the Configuration.scheduler_policy
* field is used to index the scheduler table.
*/
#define _Scheduler_USER (0)
@@ -47,16 +47,15 @@ extern "C" {
typedef struct Scheduler_Control_struct Scheduler_Control;
/*
* The Scheduler_Table_t type defines the scheduler initialization table,
* which is set up by confdefs.h based on the user's choice of scheduler
* policy.
* This type defines the scheduler initialization table entry, which is set up
* by confdefs.h based on the user's choice of scheduler policy.
*/
typedef struct {
void ( *scheduler_init )( Scheduler_Control * );
} Scheduler_Table_t;
} Scheduler_Table_entry;
/* instantiated and initialized in confdefs.h */
extern const Scheduler_Table_t _Scheduler_Table[];
extern const Scheduler_Table_entry _Scheduler_Table[];
/**
* The following Scheduler_Per_thread_xxx structures are used to
@@ -119,12 +118,12 @@ struct Scheduler_Control_struct {
* This is the set of lists (an array of Chain_Control) for
* priority scheduling.
*/
Chain_Control *Priority;
Chain_Control *priority;
} ready_queues;
} Ready_queues;
/** The jump table for scheduler-specific functions */
Scheduler_Operations operations;
Scheduler_Operations Operations;
};
/**
@@ -51,7 +51,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_Schedule(
Scheduler_Control *the_scheduler
)
{
the_scheduler->operations.schedule( the_scheduler );
the_scheduler->Operations.schedule( the_scheduler );
}
/** @brief _Scheduler_Yield
@@ -63,7 +63,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_Schedule(
*/
RTEMS_INLINE_ROUTINE void _Scheduler_Yield( void )
{
_Scheduler.operations.yield( &_Scheduler );
_Scheduler.Operations.yield( &_Scheduler );
}
/** @brief _Scheduler_Block
@@ -78,7 +78,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_Block(
Thread_Control *the_thread
)
{
the_scheduler->operations.block( the_scheduler, the_thread );
the_scheduler->Operations.block( the_scheduler, the_thread );
}
/** @brief _Scheduler_Unblock
@@ -93,7 +93,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_Unblock(
Thread_Control *the_thread
)
{
the_scheduler->operations.unblock( the_scheduler, the_thread );
the_scheduler->Operations.unblock( the_scheduler, the_thread );
}
/** @brief _Scheduler_Thread_scheduler_allocate
@@ -106,7 +106,7 @@ RTEMS_INLINE_ROUTINE void* _Scheduler_Thread_scheduler_allocate(
)
{
return
the_scheduler->operations.scheduler_allocate( the_scheduler, the_thread );
the_scheduler->Operations.scheduler_allocate( the_scheduler, the_thread );
}
/** @brief _Scheduler_Thread_scheduler_free
@@ -118,7 +118,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_Thread_scheduler_free(
Thread_Control *the_thread
)
{
return the_scheduler->operations.scheduler_free( the_scheduler, the_thread );
return the_scheduler->Operations.scheduler_free( the_scheduler, the_thread );
}
/** @brief _Scheduler_Thread_scheduler_update
@@ -130,7 +130,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_Thread_scheduler_update(
Thread_Control *the_thread
)
{
the_scheduler->operations.scheduler_update( the_scheduler, the_thread );
the_scheduler->Operations.scheduler_update( the_scheduler, the_thread );
}
/**@}*/
@@ -34,17 +34,17 @@
RTEMS_INLINE_ROUTINE void _Scheduler_priority_Ready_queue_initialize(
Scheduler_Control *the_scheduler
) {
uint32_t index;
size_t index;
/* allocate ready queue structures */
the_scheduler->ready_queues.Priority = (Chain_Control *)
the_scheduler->Ready_queues.priority = (Chain_Control *)
_Workspace_Allocate_or_fatal_error(
(PRIORITY_MAXIMUM + 1) * sizeof(Chain_Control)
((size_t) PRIORITY_MAXIMUM + 1) * sizeof(Chain_Control)
);
/* initialize ready queue structures */
for( index=0; index <= PRIORITY_MAXIMUM; index++)
_Chain_Initialize_empty( &the_scheduler->ready_queues.Priority[index] );
_Chain_Initialize_empty( &the_scheduler->Ready_queues.priority[index] );
}
/*
@@ -194,7 +194,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_priority_Schedule_body(
)
{
_Thread_Heir = _Scheduler_priority_Ready_queue_first(
the_scheduler->ready_queues.Priority
the_scheduler->Ready_queues.priority
);
}
@@ -250,7 +250,7 @@ RTEMS_INLINE_ROUTINE void _Scheduler_priority_Block_body(
*/
RTEMS_INLINE_ROUTINE void _Scheduler_priority_Unblock_body (
Scheduler_Control *the_scheduler,
Scheduler_Control *the_scheduler __attribute__((unused)),
Thread_Control *the_thread
)
{
+7 -7
View File
@@ -50,15 +50,15 @@ void _Scheduler_priority_Initialize (
* for the scheduler. Every scheduler implementation provides its own
* scheduler operations table.
*/
the_scheduler->operations.schedule = &_Scheduler_priority_Schedule;
the_scheduler->operations.yield = &_Scheduler_priority_Yield;
the_scheduler->operations.block = &_Scheduler_priority_Block;
the_scheduler->operations.unblock = &_Scheduler_priority_Unblock;
the_scheduler->operations.scheduler_allocate =
the_scheduler->Operations.schedule = &_Scheduler_priority_Schedule;
the_scheduler->Operations.yield = &_Scheduler_priority_Yield;
the_scheduler->Operations.block = &_Scheduler_priority_Block;
the_scheduler->Operations.unblock = &_Scheduler_priority_Unblock;
the_scheduler->Operations.scheduler_allocate =
&_Scheduler_priority_Thread_scheduler_allocate;
the_scheduler->operations.scheduler_free =
the_scheduler->Operations.scheduler_free =
&_Scheduler_priority_Thread_scheduler_free;
the_scheduler->operations.scheduler_update =
the_scheduler->Operations.scheduler_update =
&_Scheduler_priority_Thread_scheduler_update;
_Scheduler_priority_Ready_queue_initialize( the_scheduler );
@@ -39,7 +39,7 @@
*/
void* _Scheduler_priority_Thread_scheduler_allocate (
Scheduler_Control *the_scheduler,
Scheduler_Control *the_scheduler __attribute__((unused)),
Thread_Control *the_thread
)
{
@@ -38,7 +38,7 @@
*/
void _Scheduler_priority_Thread_scheduler_free (
Scheduler_Control *the_scheduler,
Scheduler_Control *the_scheduler __attribute__((unused)),
Thread_Control *the_thread
)
{
@@ -43,7 +43,7 @@ void _Scheduler_priority_Thread_scheduler_update (
Thread_Control *the_thread
)
{
Chain_Control *rq = the_scheduler->ready_queues.Priority;
Chain_Control *rq = the_scheduler->Ready_queues.priority;
the_thread->scheduler.priority->ready_chain = &rq[
the_thread->current_priority
];
+1 -1
View File
@@ -50,7 +50,7 @@
*/
void _Scheduler_priority_Yield(
Scheduler_Control *the_scheduler
Scheduler_Control *the_scheduler __attribute__((unused))
)
{
ISR_Level level;