Commit 688d8c30 by malcolm

Oops switch is a reserved word

parent 4b681222
Showing with 4 additions and 3 deletions
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
#define _PCB_INC #define _PCB_INC
#include <stdint.h> #include <stdint.h>
#include "mem.h"
typedef struct//all regs in proc typedef struct//all regs in proc
{ {
...@@ -49,7 +50,7 @@ typedef struct//regs needed for context ...@@ -49,7 +50,7 @@ typedef struct//regs needed for context
typedef struct typedef struct
{ {
uint32_t mem; page_directory_entry* mem;
volatile int pid; volatile int pid;
struct process* parent; struct process* parent;
trapframe* tf; trapframe* tf;
...@@ -57,6 +58,6 @@ typedef struct ...@@ -57,6 +58,6 @@ typedef struct
char name[32]; char name[32];
}__attribute__((packed)) process; }__attribute__((packed)) process;
extern void switch(context** old, context* new); extern void context_switch(context** old, context* new);
#endif #endif
global switch global context_switch
switch: switch:
mov eax, [esp+4] mov eax, [esp+4]
mov edx, [esp+8] mov edx, [esp+8]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment