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

@ -2,13 +2,11 @@
#include <stddef.h>
#include <system/system.h>
#include <sysdefs/processctl.h>
#include <sysdefs/devctl.h>
#include <errors.h>
#include <uprintf.h>
#include <log.h>
#include <util/util.h>
#include <umalloc/umalloc.h>
#include <devids.h>
extern void main(void);
extern uint8_t _bss_start[];

11
ulib/dev.h Normal file
View File

@ -0,0 +1,11 @@
#ifndef ULIB_DEV_H_
#define ULIB_DEV_H_
#define DEV_TERMDEV 0
#define DEV_PS2KBDEV 1
#define DEV_TERMDEV_PUTCH 0
#define DEV_PS2KBDEV_READCH 0
#endif // ULIB_DEV_H_

View File

@ -1,9 +0,0 @@
#ifndef ULIB_DEVIDS_H_
#define ULIB_DEVIDS_H_
enum {
DEV_TERMDEV = 0x10,
DEV_PS2KBDEV = 0x11,
};
#endif // ULIB_DEVIDS_H_

View File

@ -16,7 +16,7 @@
#include <log.h>
#include <assert.h>
#include <umalloc/umalloc.h>
#include <devids.h>
#include <dev.h>
#include <errors.h>
#include <sysdefs/ioctl.h>