mutek/scheduler.h header reference
[Kernel services module]

The source code of this header can be browsed online.

Description [link] 

Kernel execution context scheduler

Members [link] 

Types [link] 

Functions [link] 

Variables [link] 

Macro [link] 

Members detail [link] 

#define GCT_CONTAINER_ALGO_sched_queue [link] 

This macro is declared in mutek/scheduler.h source file, line 49.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

#define GCT_CONTAINER_LOCK_sched_queue [link] 

This macro is declared in mutek/scheduler.h source file, line 50.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

#define MUTEK_SCHEDULER_H_ [link] 

This macro is declared in mutek/scheduler.h source file, line 23.

#define SCHED_CANDIDATE_FCN(n) [link] 

This macro is declared in mutek/scheduler.h source file, line 37.

scheduler context candidate checking function

#define SCHED_QUEUE_INITIALIZER [link] 

This macro is declared in mutek/scheduler.h source file, line 82.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

void sched_affinity_add(struct sched_context_s *sched_ctx, cpu_id_t cpu) [link] 

This function is declared in mutek/scheduler.h source file, line 233.

This function function set processor affinity sothat scheduler context will run on this cpu

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

void sched_affinity_all(struct sched_context_s *sched_ctx) [link] 

This function is declared in mutek/scheduler.h source file, line 248.

This function function set processor affinity sothat scheduler context will run on all cpu

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

void sched_affinity_clear(struct sched_context_s *sched_ctx) [link] 

This function is declared in mutek/scheduler.h source file, line 253.

This function function set processor affinity sothat scheduler context will run on all cpu

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

void sched_affinity_remove(struct sched_context_s *sched_ctx, cpu_id_t cpu) [link] 

This function is declared in mutek/scheduler.h source file, line 238.

This function function set processor affinity sothat scheduler context will not run on this cpu

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

void sched_affinity_single(struct sched_context_s *sched_ctx, cpu_id_t cpu) [link] 

This function is declared in mutek/scheduler.h source file, line 243.

This function function set processor affinity sothat scheduler context will run on a single cpu

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

typedef bool_t (sched_candidate_fcn_t)(struct sched_context_s *sched_ctx) [link] 

This typedef is declared in mutek/scheduler.h source file, line 41.

scheduler context candidate checking function type

This declaration involves expansion of the SCHED_CANDIDATE_FCN macro.

void sched_context_candidate_fcn(struct sched_context_s *sched_ctx, sched_candidate_fcn_t *fcn) [link] 

This function is declared in mutek/scheduler.h source file, line 258.

This function function setups a scheduler context candidate checking function.

This is available when CONFIG_MUTEK_CONTEXT_SCHED_CANDIDATE_FCN is defined.

void sched_context_exit(void ) [link] 

This function is declared in mutek/scheduler.h source file, line 169.

This function jumps to next context without saving current context. current context will be lost. Must be called with interrupts disabled and main sched queue locked.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

See also sched_preempt_stop.

void sched_context_init(struct sched_context_s *sched_ctx, struct context_s *context) [link] 

This function is declared in mutek/scheduler.h source file, line 149.

This function initializes scheduler context.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

struct sched_context_s [link] 

This struct is declared in persist/persist.h source file, line 192.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

FieldDescription
struct scheduler_s * scheduler;keep track of associated scheduler queue
struct context_s * context;execution context
void * priv;
uint8_t priority;
cpu_bitmap_t cpu_map;
sched_candidate_fcn_t * is_candidate;

See also sched_queue_item_t.

void sched_context_start(struct sched_context_s *sched_ctx) [link] 

This function is declared in mutek/scheduler.h source file, line 187.

This function enqueues scheduler context for execution. Must be called with interrupts disabled

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

void sched_context_switch(void ) [link] 

This function is declared in mutek/scheduler.h source file, line 160.

This function switches to next context. Must be called with interrupts disabled.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

See also sched_preempt_switch.

void sched_context_wake(sched_queue_root_t *queue, struct sched_context_s *sched_ctx) [link] 

This function is declared in mutek/scheduler.h source file, line 228.

This function function removes a given context from passed queue and push it back in running queue. This function Must be called with interrupts disabled and queue locked.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

struct sched_context_s * sched_get_current(void ) [link] 

This function is declared in mutek/scheduler.h source file, line 99.

This function returns the current scheduler context

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

struct context_s * sched_preempt_stop(void ) [link] 

This function is declared in mutek/scheduler.h source file, line 129.

This function is a context preemption handler.

This function returns next scheduler candidate or processor idle context if none is available. Current context is not pushed back on running queue.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

See also context_set_preempt, CONTEXT_PREEMPT and sched_context_stop.

struct context_s * sched_preempt_switch(void ) [link] 

This function is declared in mutek/scheduler.h source file, line 119.

This function is a context preemption handler.

This function pushes current context back on running queue and returns next scheduler candidate. If no other context is available on running queue, this function does nothing and return NULL.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

See also context_set_preempt, CONTEXT_PREEMPT and sched_context_switch.

struct context_s * sched_preempt_wait_unlock(void ) [link] 

This function is declared in mutek/scheduler.h source file, line 140.

This function is a context preemption handler.

This function pushes current context on the wait queue specified in sched_preempt_wait_unlock_q. The function unlocks the queue and returns the next candidate context which may be the processor idle context.

This is available when CONFIG_MUTEK_CONTEXT_SCHED and CONFIG_HEXO_CONTEXT_PREEMPT are both defined.

See also context_set_preempt, CONTEXT_PREEMPT and sched_wait_unlock.

sched_queue_root_t * sched_preempt_wait_unlock_q [link] 

This variable is declared in mutek/scheduler.h source file, line 144.

This is available when CONFIG_MUTEK_CONTEXT_SCHED and CONFIG_HEXO_CONTEXT_PREEMPT are both defined.

This declaration involves expansion of the CPU_LOCAL macro.

See also sched_preempt_wait_unlock.

void sched_queue_destroy(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 213.

This function frees resources associated with context queue.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

typedef void * sched_queue_entry_t [link] 

This typedef is declared in mutek/scheduler.h source file, line 75.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

error_t sched_queue_init(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 209.

This function initializes context queue.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

typedef struct sched_context_s * sched_queue_item_t [link] 

This typedef is declared in mutek/scheduler.h source file, line 75.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

void sched_queue_rdlock(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 201.

This function locks context queue for reading.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

typedef void * sched_queue_root_t [link] 

This typedef is declared in mutek/scheduler.h source file, line 75.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

typedef struct __empty_s sched_queue_root_t [link] 

This typedef is declared in mutek/scheduler.h source file, line 91.

Preprocessor condition: not defined( CONFIG_MUTEK_CONTEXT_SCHED )

void sched_queue_unlock(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 205.

This function unlocks context queue.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

void sched_queue_wrlock(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 197.

This function locks context queue for writting.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

void sched_stop_unlock(lock_t *lock) [link] 

This function is declared in mutek/scheduler.h source file, line 193.

This function switches to next context without pushing current context back in running queue and unlock passed scheduler queue.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

See also sched_context_stop.

struct context_s * sched_tmp_context(void ) [link] 

This function is declared in mutek/scheduler.h source file, line 109.

This function returns a cpu local context for temporary stack use with cpu_context_stack_use, useful to run other context exit/destroy. The processor idle context is actually returned. This context must be used with interrupts disabled.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

typedef void (sched_wait_cb_t)(void *ctx) [link] 

This typedef is declared in mutek/scheduler.h source file, line 215.

void sched_wait_unlock(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 182.

This function pushes current context in the 'queue', unlock it and switch to next context available in the 'root' queue. Must be called with interrupts disabled.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

See also sched_preempt_wait_unlock.

struct sched_context_s * sched_wake(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 222.

This function removes first context from passed queue and push it back in running queue. This function returns a pointer to context or NULL if queue was empty. This function Must be called with interrupts disabled and queue locked.

This is available when CONFIG_MUTEK_CONTEXT_SCHED is defined.

struct sched_context_s * sched_cur [link] 

This variable is declared in mutek/scheduler.h source file, line 86.

This variable is for internal use only.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

struct sched_context_s sched_idle [link] 

This variable is declared in mutek/scheduler.h source file, line 88.

This variable is for internal use only.

Preprocessor condition: defined( CONFIG_MUTEK_CONTEXT_SCHED )

This declaration involves expansion of the CPU_LOCAL macro.

struct context_s * sched_wait_unlock_ctx(sched_queue_root_t *queue) [link] 

This function is declared in mutek/scheduler.h source file, line 173.

This function is for internal use only.

Valid XHTML 1.0 StrictGenerated by diaxen on Thu Aug 4 15:44:06 2022 using MkDoc