Magellan Linux

Annotation of /trunk/mkinitrd-magellan/klibc/usr/klibc/arch/i386/varsyscall.S

Parent Directory Parent Directory | Revision Log Revision Log


Revision 532 - (hide annotations) (download)
Sat Sep 1 22:45:15 2007 UTC (16 years, 8 months ago) by niro
File size: 621 byte(s)
-import if magellan mkinitrd; it is a fork of redhats mkinitrd-5.0.8 with all magellan patches and features; deprecates magellan-src/mkinitrd

1 niro 532 /*
2     * arch/i386/varsyscall.S
3     *
4     * Common tail-handling code for varadic system calls (which always
5     * use the cdecl convention.)
6     *
7     * The arguments are on the stack; the system call number in %eax.
8     */
9    
10     #ifdef _REGPARM
11    
12     #define ARG(n) (4*n+20)(%esp)
13    
14     .text
15     .align 4
16     .globl __syscall_varadic
17     .type __syscall_varadic,@function
18     __syscall_varadic:
19     popl %eax
20     pushl %ebx
21     pushl %esi
22     pushl %edi
23     pushl %ebp
24    
25     movl ARG(0),%ebx # Syscall arguments
26     movl ARG(1),%ecx
27     movl ARG(2),%edx
28     movl ARG(3),%esi
29     movl ARG(4),%edi
30     movl ARG(5),%ebp
31    
32     jmp __syscall_common_tail
33    
34     .size __syscall_varadic,.-__syscall_varadic
35    
36     #endif