Run first app from ramdisk!

This commit is contained in:
2025-12-29 23:54:21 +01:00
parent c16170e4c2
commit fa7998c323
56 changed files with 5443 additions and 229 deletions

View File

@@ -5,21 +5,31 @@
#include <amd64/tss.h>
#include <aux/compiler.h>
#include <libk/std.h>
#include <proc/proc.h>
#define CPUS_MAX 32
struct cpu {
uint64_t lapic_ticks;
uint32_t id;
struct {
uint64_t rflags;
atomic_int nesting;
} irq_ctx;
uint8_t user_stack[USTACK_SIZE] ALIGNED (16);
volatile uint8_t kernel_stack[KSTACK_SIZE] ALIGNED (16);
volatile uint8_t except_stack[KSTACK_SIZE] ALIGNED (16);
volatile uint8_t irq_stack[KSTACK_SIZE] ALIGNED (16);
volatile struct gdt_extended gdt ALIGNED (16);
volatile struct tss tss;
spin_lock_t lock;
struct proc* proc_run_q;
struct proc* proc_current;
};
struct cpu* cpu_make (void);