diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2011-03-16 16:32:22 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2011-03-16 16:32:22 +0000 |
commit | 0118ed65ea96db1032771620fc5fb1c1290f9d47 (patch) | |
tree | 30a21550f5c2fc753634491040113fce235a3b5c /cpukit/sapi | |
parent | 2011-03-16 Joel Sherrill <joel.sherrill@oarcorp.com> (diff) | |
download | rtems-0118ed65ea96db1032771620fc5fb1c1290f9d47.tar.bz2 |
2011-03-16 Jennifer Averett <jennifer.averett@OARcorp.com>
PR 1743/cpu
* sapi/include/confdefs.h, score/Makefile.am, score/preinstall.am: Add
Simple Priority Scheduler as complement to existing Deterministic
Priority Scheduler. This scheduler serves both as an example and as a
lighter weight implementation for smaller systems.
* score/include/rtems/score/schedulersimple.h,
score/inline/rtems/score/schedulersimple.inl,
score/src/schedulersimple.c, score/src/schedulersimpleblock.c,
score/src/schedulersimpleenqueue.c,
score/src/schedulersimpleenqueuefirst.c,
score/src/schedulersimpleextract.c,
score/src/schedulersimplereadyqueueenqueue.c,
score/src/schedulersimplereadyqueueenqueuefirst.c,
score/src/schedulersimpleschedule.c,
score/src/schedulersimpleunblock.c, score/src/schedulersimpleyield.c:
New files.
Diffstat (limited to 'cpukit/sapi')
-rw-r--r-- | cpukit/sapi/include/confdefs.h | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/cpukit/sapi/include/confdefs.h b/cpukit/sapi/include/confdefs.h index f7ce50ec76..d194fed1bc 100644 --- a/cpukit/sapi/include/confdefs.h +++ b/cpukit/sapi/include/confdefs.h @@ -556,6 +556,7 @@ rtems_fs_init_functions_t rtems_fs_init_helper = * scheduling policy to use. The supported configurations are: * CONFIGURE_SCHEDULER_USER - user provided scheduler * CONFIGURE_SCHEDULER_PRIORITY - Deterministic Priority Scheduler + * CONFIGURE_SCHEDULER_SIMPLE - Light-weight Priority Scheduler * * If no configuration is specified by the application, then * CONFIGURE_SCHEDULER_PRIORITY is assumed to be the default. @@ -575,7 +576,8 @@ rtems_fs_init_functions_t rtems_fs_init_helper = /* If no scheduler is specified, the priority scheduler is default. */ #if !defined(CONFIGURE_SCHEDULER_USER) && \ - !defined(CONFIGURE_SCHEDULER_PRIORITY) + !defined(CONFIGURE_SCHEDULER_PRIORITY) && \ + !defined(CONFIGURE_SCHEDULER_SIMPLE) #define CONFIGURE_SCHEDULER_PRIORITY #endif @@ -598,6 +600,22 @@ rtems_fs_init_functions_t rtems_fs_init_helper = #endif /* + * If the Simple Priority Scheduler is selected, then configure for it. + */ +#if defined(CONFIGURE_SCHEDULER_SIMPLE) + #include <rtems/score/schedulersimple.h> + #define SCHEDULER_ENTRY_POINTS SCHEDULER_SIMPLE_ENTRY_POINTS + + /** + * define the memory used by the simple scheduler + */ + #define CONFIGURE_MEMORY_FOR_SCHEDULER ( \ + _Configure_From_workspace( sizeof(Chain_Control) ) \ + ) + #define CONFIGURE_MEMORY_PER_TASK_FOR_SCHEDULER (0) +#endif + +/* * Set up the scheduler entry points table. The scheduling code uses * this code to know which scheduler is configured by the user. */ |