MOS Source Code
Loading...
Searching...
No Matches
kthread.cpp File Reference
+ Include dependency graph for kthread.cpp:

Go to the source code of this file.

Classes

struct  kthread_arg_t
 

Functions

static void kthread_entry (void *arg)
 
void kthread_init (void)
 
Threadkthread_create (thread_entry_t entry, void *arg, const char *name)
 Create a kernel-mode thread.
 
Threadkthread_create_no_sched (thread_entry_t entry, void *arg, const char *name)
 Create a kernel thread, but do not add it to the scheduler.
 

Variables

static Processkthreadd
 

Function Documentation

◆ kthread_entry()

static void kthread_entry ( void * arg)
static

Definition at line 22 of file kthread.cpp.

Referenced by kthread_create_no_sched().

+ Here is the call graph for this function:

◆ kthread_init()

void kthread_init ( void )

Definition at line 30 of file kthread.cpp.

Referenced by mos_start_kernel().

+ Here is the call graph for this function:

◆ kthread_create()

Thread * kthread_create ( thread_entry_t entry,
void * arg,
const char * name )

Create a kernel-mode thread.

Parameters
entryThe entry point of the thread
argThe argument to pass to the thread
nameThe name of the thread
Returns
Thread* The created thread

Definition at line 37 of file kthread.cpp.

Referenced by userfs_manager_rpc_init().

+ Here is the call graph for this function:

◆ kthread_create_no_sched()

Thread * kthread_create_no_sched ( thread_entry_t entry,
void * arg,
const char * name )

Create a kernel thread, but do not add it to the scheduler.

Parameters
entryThe entry point of the thread
argThe argument to pass to the thread
nameThe name of the thread
Returns
Thread* The created thread

Definition at line 44 of file kthread.cpp.

Referenced by create_idle_task(), and kthread_create().

+ Here is the call graph for this function:

Variable Documentation

◆ kthreadd

Process* kthreadd
static

Definition at line 14 of file kthread.cpp.

Referenced by kthread_create_no_sched(), and kthread_init().