ArvernOS
Loading...
Searching...
No Matches
proc.h File Reference
#include <proc/task.h>
Include dependency graph for proc.h:

Functions

task_tarch_task_init ()
 
void arch_task_switch (task_t *prev, task_t *next)
 
task_tarch_task_create (uint64_t clone_flags, uintptr_t entrypoint)
 

Function Documentation

◆ arch_task_create()

task_t * arch_task_create ( uint64_t clone_flags,
uintptr_t entrypoint )

Creates a new task.

This function is called by task_create().

Parameters
clone_flagsconfiguration flags
entrypointthe entrypoint of the task
Returns
a task

◆ arch_task_init()

task_t * arch_task_init ( )

Creates and returns the initial task.

This function is called by task_init().

Returns
the initial task

◆ arch_task_switch()

void arch_task_switch ( task_t * prev,
task_t * next )

Switches to a new task.

This function is called by task_switch(), which is called by task_schedule() and task_schedule_on_timer_tick().

Parameters
prevthe task that should be stopped
nextthe task that should be started