2011-09-11 Petr Benes <benesp16@fel.cvut.cz>

PR 1896/cpukit
	* sapi/include/confdefs.h, score/Makefile.am, score/preinstall.am: Add
	Earliest Deadline First (EDF) Scheduling Algorithm implementation.
	* score/include/rtems/score/scheduleredf.h, score/src/scheduleredf.c,
	score/src/scheduleredfallocate.c, score/src/scheduleredfblock.c,
	score/src/scheduleredfenqueue.c,
	score/src/scheduleredfenqueuefirst.c,
	score/src/scheduleredfextract.c, score/src/scheduleredffree.c,
	score/src/scheduleredfprioritycompare.c,
	score/src/scheduleredfreleasejob.c, score/src/scheduleredfschedule.c,
	score/src/scheduleredfunblock.c, score/src/scheduleredfupdate.c,
	score/src/scheduleredfyield.c: New files.
This commit is contained in:
Joel Sherrill
2011-09-11 20:52:37 +00:00
parent 72b7935545
commit 5472ad414f
18 changed files with 819 additions and 1 deletions
+19 -1
View File
@@ -573,6 +573,7 @@ rtems_fs_init_functions_t rtems_fs_init_helper =
* CONFIGURE_SCHEDULER_PRIORITY - Deterministic Priority Scheduler
* CONFIGURE_SCHEDULER_SIMPLE - Light-weight Priority Scheduler
* CONFIGURE_SCHEDULER_SIMPLE_SMP - Simple SMP Priority Scheduler
* CONFIGURE_SCHEDULER_EDF - EDF Scheduler
*
* If no configuration is specified by the application, then
* CONFIGURE_SCHEDULER_PRIORITY is assumed to be the default.
@@ -598,7 +599,8 @@ rtems_fs_init_functions_t rtems_fs_init_helper =
#if !defined(CONFIGURE_SCHEDULER_USER) && \
!defined(CONFIGURE_SCHEDULER_PRIORITY) && \
!defined(CONFIGURE_SCHEDULER_SIMPLE) && \
!defined(CONFIGURE_SCHEDULER_SIMPLE_SMP)
!defined(CONFIGURE_SCHEDULER_SIMPLE_SMP) && \
!defined(CONFIGURE_SCHEDULER_EDF)
#if defined(RTEMS_SMP) && defined(CONFIGURE_SMP_APPLICATION)
#define CONFIGURE_SCHEDULER_SIMPLE_SMP
#else
@@ -658,6 +660,22 @@ rtems_fs_init_functions_t rtems_fs_init_helper =
#define CONFIGURE_MEMORY_PER_TASK_FOR_SCHEDULER (0)
#endif
/*
* If the EDF Scheduler is selected, then configure for it.
*/
#if defined(CONFIGURE_SCHEDULER_EDF)
#include <rtems/score/scheduleredf.h>
#define CONFIGURE_SCHEDULER_ENTRY_POINTS SCHEDULER_EDF_ENTRY_POINTS
/**
* define the memory used by the EDF scheduler
*/
#define CONFIGURE_MEMORY_FOR_SCHEDULER ( \
_Configure_From_workspace(0))
#define CONFIGURE_MEMORY_PER_TASK_FOR_SCHEDULER ( \
_Configure_From_workspace(sizeof(Scheduler_EDF_Per_thread)))
#endif
#if defined(CONFIGURE_SCHEDULER_USER)
#define CONFIGURE_SCHEDULER_ENTRY_POINTS \
CONFIGURE_SCHEDULER_USER_ENTRY_POINTS