kernel: Introduce scheduler modes of operation

This commit is contained in:
Pawel Dziepak
2013-10-21 02:17:00 +02:00
parent 4b446279e6
commit cd8d4e39fd
3 changed files with 83 additions and 2 deletions
+11
View File
@@ -17,6 +17,13 @@ struct scheduling_analysis;
struct SchedulerListener;
typedef enum scheduler_mode {
SCHEDULER_MODE_PERFORMANCE,
SCHEDULER_MODE_POWER_SAVING,
// ...
SCHEDULER_MODE_COUNT
} scheduler_mode;
struct scheduler_ops {
/*! Enqueues the thread in the ready-to-run queue.
The caller must hold the scheduler lock (with disabled interrupts).
@@ -68,6 +75,10 @@ struct scheduler_ops {
*/
void (*start)(void);
/*! Sets scheduler operation mode.
*/
status_t (*set_operation_mode)(scheduler_mode mode);
/*! Dumps scheduler specific thread information.
*/
void (*dump_thread_data)(Thread* thread);