matos/core/process.h

21 lines
693 B
C
Raw Permalink Normal View History

2021-10-30 15:30:19 +02:00
#pragma once
#include "thread.h"
#define PROCESS_NAME_MAX_LENGTH 32
struct process;
int processSetup();
struct process *processCreate(char *name);
int processCountThread(struct process *proc);
void processListPrint();
int processRef(struct process *proc);
int processUnref(struct process *proc);
int processSetName(struct process *proc, char *name);
2024-01-26 22:23:58 +01:00
char *processGetName(struct process *proc);
2021-10-30 15:30:19 +02:00
int processAddThread(struct process *proc, struct thread *th);
2021-10-30 15:43:40 +02:00
int processRemoveThread(struct thread *th);
2021-11-02 21:24:12 +01:00
struct mmu_context *processGetMMUContext(struct process *th);
2022-08-09 16:15:00 +02:00
struct uAddrSpace *processGetAddrSpace(struct process *proc);
int processInitHeap(struct process *proc, uaddr_t lastUserAddr);