Store device structs in a dynamic list

This commit is contained in:
2025-10-03 22:25:16 +02:00
parent c0178a1405
commit 57ba9ff126
10 changed files with 44 additions and 24 deletions

View File

@ -6,6 +6,8 @@
#include "dev.h"
#include "errors.h"
#include "dlmalloc/malloc.h"
#include "util/util.h"
#include "syscall/devctl.h"
Dev PS2KBDEV;
Ps2KbFastBuf PS2KB_BUF;
@ -32,4 +34,5 @@ void ps2kbdev_init(void) {
uint8_t *buf = dlmalloc(bufsz);
rbuf_init(&PS2KB_BUF.rbuf, buf, bufsz);
PS2KB_BUF.init = true;
LL_APPEND(DEVS, &PS2KBDEV);
}