All checks were successful
Build documentation / build-and-deploy (push) Successful in 24s
27 lines
675 B
C
27 lines
675 B
C
#ifndef _KERNEL_PROC_SUSPENTION_Q_H
|
|
#define _KERNEL_PROC_SUSPENTION_Q_H
|
|
|
|
#include <libk/list.h>
|
|
#include <sync/spin_lock.h>
|
|
|
|
struct proc;
|
|
|
|
struct proc_suspension_q {
|
|
struct list_node_link* proc_list;
|
|
spin_lock_t lock;
|
|
};
|
|
|
|
struct proc_sq_entry {
|
|
struct list_node_link sq_link;
|
|
struct list_node_link proc_link;
|
|
struct proc* proc;
|
|
struct proc_suspension_q* sq;
|
|
};
|
|
|
|
void proc_sqs_cleanup (struct proc* proc);
|
|
void proc_sq_suspend (struct proc* proc, struct proc_suspension_q* sq, spin_lock_t* resource_lock,
|
|
spin_lock_ctx_t* ctxrl);
|
|
void proc_sq_resume (struct proc* proc, struct proc_sq_entry* sq_entry);
|
|
|
|
#endif // _KERNEL_PROC_SUSPENTION_Q_H
|