Changeset 204674e in mainline for arch/ia32/src/interrupt.c


Ignore:
Timestamp:
2006-01-15T16:49:10Z (20 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
4be51c8
Parents:
81703f9
Message:

"Hello world" from user space :)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • arch/ia32/src/interrupt.c

    r81703f9 r204674e  
    2828
    2929#include <arch/interrupt.h>
     30#include <syscall/syscall.h>
    3031#include <print.h>
    3132#include <debug.h>
     
    111112}
    112113
    113 void syscall(int n, void *stack)
     114void syscall(int n, void *st)
    114115{
    115         printf("cpu%d: syscall\n", CPU->id);
    116         thread_usleep(1000);
     116        __native *stack = (__native *) st;
     117       
     118        if (stack[-2] < SYSCALL_END)
     119                syscall_table[stack[-2]](stack[-5], stack[-3], stack[-4]);
     120        else
     121                panic("Undefined syscall %d", stack[-2]);
    117122}
    118123
Note: See TracChangeset for help on using the changeset viewer.