diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1994-12-01 08:00:00 +0000 |
---|---|---|
committer | <ralf@linux-mips.org> | 1994-12-01 08:00:00 +0000 |
commit | 90ecc248e200fee448001248dde0ca540dd3ef64 (patch) | |
tree | a3fe89494ce63b4835f0f9cf5c45e74cde88252b /lib/_exit.c | |
parent | 1513ff9b7899ab588401c89db0e99903dbf5f886 (diff) |
Import of Linux/MIPS 1.1.68
Diffstat (limited to 'lib/_exit.c')
-rw-r--r-- | lib/_exit.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/lib/_exit.c b/lib/_exit.c index a46f1a2b6..7126235a8 100644 --- a/lib/_exit.c +++ b/lib/_exit.c @@ -10,9 +10,21 @@ volatile void _exit(int exit_code) { fake_volatile: +#if defined (__i386__) __asm__("movl %1,%%ebx\n\t" "int $0x80" : /* no outputs */ :"a" (__NR_exit),"g" (exit_code)); +#elif defined (__mips__) + __asm__(".set noat\n\t" + "move $2,%1\n\t" + "li $1,%0\n\t" + "syscall\n\t" + ".set at" + : /* no outputs */ + : "i" (__NR_exit), "r" (exit_code) + : "$1","$2"); +#endif goto fake_volatile; } + |