重构内存分配器、增加中断支持、整理rust运行时环境 #4

Merged
pointer-to-bios merged 39 commits from downstream into main 2024-04-11 00:36:14 +08:00
1 changed files with 15 additions and 1 deletions
Showing only changes of commit 341ca618de - Show all commits

View File

@ -8,6 +8,20 @@
#define into_bytes(addr) ((u8 *)(addr))
#define bytes_into(bytes, type) ((type *)(bytes))
void pointer_to_string(u64 addr, char * dest);
void pointer_to_string(u64 addr, char *dest);
typedef struct __va_args
{
usize length;
void *args[0];
} va_args;
#define va_args_gen(result, length) \
void *__reserved__[length]; \
va_args __va_args__; \
result = &__va_args__;
#define va_args_set(vaargs, index, val) \
vaargs->args[index] = &val;
#endif