]>
Commit | Line | Data |
---|---|---|
b168057a | 1 | /* Copyright (C) 1995-2015 Free Software Foundation, Inc. |
b5791037 | 2 | This file is part of the GNU C Library. |
28f540f4 | 3 | |
b5791037 | 4 | The GNU C Library is free software; you can redistribute it and/or |
41bdb6e2 AJ |
5 | modify it under the terms of the GNU Lesser General Public |
6 | License as published by the Free Software Foundation; either | |
7 | version 2.1 of the License, or (at your option) any later version. | |
28f540f4 | 8 | |
b5791037 UD |
9 | The GNU C Library is distributed in the hope that it will be useful, |
10 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
11 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
41bdb6e2 | 12 | Lesser General Public License for more details. |
28f540f4 | 13 | |
41bdb6e2 | 14 | You should have received a copy of the GNU Lesser General Public |
59ba27a6 PE |
15 | License along with the GNU C Library; if not, see |
16 | <http://www.gnu.org/licenses/>. */ | |
28f540f4 RM |
17 | |
18 | #include <sysdep.h> | |
19 | ||
cccda09f | 20 | /* Please consult the file sysdeps/unix/sysv/linux/i386/sysdep.h for |
b5791037 | 21 | more information about the value -4095 used below.*/ |
cccda09f | 22 | |
c14e4c32 | 23 | .text |
439d1d45 | 24 | ENTRY (syscall) |
6ed0492f | 25 | |
0da7bcc5 UD |
26 | PUSHARGS_6 /* Save register contents. */ |
27 | _DOARGS_6(44) /* Load arguments. */ | |
28 | movl 20(%esp), %eax /* Load syscall number into %eax. */ | |
f051627f | 29 | ENTER_KERNEL /* Do the system call. */ |
0da7bcc5 | 30 | POPARGS_6 /* Restore register contents. */ |
b5791037 | 31 | cmpl $-4095, %eax /* Check %eax for error. */ |
c0fb8a56 | 32 | jae SYSCALL_ERROR_LABEL /* Jump to error handler if error. */ |
439d1d45 | 33 | ret /* Return to caller. */ |
6ed0492f UD |
34 | |
35 | PSEUDO_END (syscall) |