Manage int IDs via id_alloc
All checks were successful
Build documentation / build-and-deploy (push) Successful in 2m31s

This commit is contained in:
2026-02-22 20:40:12 +01:00
parent 8fc5418915
commit 084809ac99
13 changed files with 203 additions and 70 deletions

View File

@@ -1,6 +1,7 @@
#ifndef _KERNEL_PROC_PROCGROUP_H
#define _KERNEL_PROC_PROCGROUP_H
#include <id/id_alloc.h>
#include <libk/list.h>
#include <libk/rbtree.h>
#include <libk/std.h>
@@ -9,6 +10,8 @@
#include <sys/mm.h>
#include <sys/procgroup.h>
#define PROCGROUP_VFS_HANDLES_MAX 256
struct proc;
struct reschedule_ctx;
@@ -32,7 +35,7 @@ struct procgroup {
struct procgroup_tls tls;
uint64_t capabilities;
struct rb_node_link* vfs_handle_tree;
int sys_vfs_handles;
struct id_alloc vfs_handle_id_alloc;
};
struct procgroup* procgroup_create (void);
@@ -48,4 +51,6 @@ bool procgroup_unmap (struct procgroup* procgroup, uintptr_t start_vaddr, size_t
struct procgroup* procgroup_find (int pgid);
void procgroup_pgid_alloc_init (void);
#endif // _KERNEL_PROC_PROCGROUP_H