diff options
| author | Michal Idziorek <m.i@gmx.at> | 2014-12-01 00:03:04 +0100 |
|---|---|---|
| committer | Michal Idziorek <m.i@gmx.at> | 2014-12-01 00:03:04 +0100 |
| commit | 0ec5b4d78c0fa1e256577f22e4265fd8a9e12197 (patch) | |
| tree | bf4b934adcbdd8ef21a194e845f629a5fbfdab60 /kernel/syscalls.c | |
| parent | b875bc86aac2c9a733ddb9b3db4ead94d2c4c053 (diff) | |
Paging between 2 'tasks' loaded from ELF files.
Both files are loaded at: 0x08048000 virutal!
Diffstat (limited to 'kernel/syscalls.c')
| -rw-r--r-- | kernel/syscalls.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/kernel/syscalls.c b/kernel/syscalls.c index 0f06479..f328248 100644 --- a/kernel/syscalls.c +++ b/kernel/syscalls.c @@ -96,6 +96,7 @@ int syscall_lseek(int file,int ptr,int dir) int syscall_write(int file, char *buf, int len) { + //x86_int_disable(); #ifdef LOG_SYSCALLS log(FOOLOS_MODULE_NAME,FOOLOS_LOG_INFO,"write(file=%d, buf=0x%08X, len=%d)", file,buf,len); #endif @@ -107,6 +108,7 @@ int syscall_write(int file, char *buf, int len) { console_put_char_green(buf[i]); } + //x86_int_enable(); return len; } @@ -189,6 +191,7 @@ int syscall_fork() int syscall_execve(char *name, char **argv, char **env) { + //x86_int_disable(); // watchout this is called with esp in virtual memory of running process! #ifdef LOG_SYSCALLS @@ -308,6 +311,8 @@ int syscall_execve(char *name, char **argv, char **env) // push addr and return to it asm("push %0"::"r"(elf->e_entry)); + +// x86_int_enable(); asm("ret"); // this is never reached! |
