diff options
| author | Miguel <m.i@gmx.at> | 2018-09-09 00:26:30 +0200 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2018-09-09 00:26:30 +0200 |
| commit | 9dabe01545644dd78448d8d489616872f14d964b (patch) | |
| tree | 83a939a54ffa27f575dbdf930140b8353f54365c /kernel/gdt.c | |
| parent | 9fde748acea83d775e367a64858414b674f05b13 (diff) | |
lapic bus speed probing and starting switch to ioapic
Diffstat (limited to 'kernel/gdt.c')
| -rw-r--r-- | kernel/gdt.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/gdt.c b/kernel/gdt.c index 0657387..bf8f203 100644 --- a/kernel/gdt.c +++ b/kernel/gdt.c @@ -7,7 +7,8 @@ #define GDT_SIZE 6 //https://wiki.osdev.org/Task_State_Segment -tss_struct sys_tss[SMP_MAX_PROC]; //Define the TSS as a global structure +//Define the TSS as a global structure, boah TODO: move to own page? +tss_struct sys_tss[SMP_MAX_PROC]; void install_tss(uint32_t cpu,uint32_t esp0){ @@ -19,6 +20,7 @@ void install_tss(uint32_t cpu,uint32_t esp0){ // now set the IO bitmap (not necessary, so set above limit) // sys_tss.iomap = ( unsigned short ) sizeof( tss_struct ); } + typedef struct GDT_struct { uint32_t base; @@ -150,6 +152,7 @@ void gdt_init() setup_gdt(gdt_struct); } + void setup_gdt(uint8_t *gdt_struct) { asm_setup_gdt(&gdt_struct[0],8*GDT_SIZE); |
