diff options
author | Roland McGrath <roland@gnu.org> | 1995-10-30 16:40:52 +0000 |
---|---|---|
committer | Roland McGrath <roland@gnu.org> | 1995-10-30 16:40:52 +0000 |
commit | 3e2ee7271dff697194c7761ca0c5836de486b36f (patch) | |
tree | 6da184ffccbf01724c58318afd82310efff9752e /sysdeps/unix/sysv | |
parent | f094496c12e93dca23d32031814f3b28e8b9546c (diff) | |
download | glibc-3e2ee7271dff697194c7761ca0c5836de486b36f.tar.gz glibc-3e2ee7271dff697194c7761ca0c5836de486b36f.tar.xz glibc-3e2ee7271dff697194c7761ca0c5836de486b36f.zip |
Thu Oct 26 23:11:11 1995 Ulrich Drepper <drepper@ipd.info.uni-karlsruhe.de>
* sysdeps/unix/sysv/linux/poll.c: Don't define as stub. Use simulation of system call using select. * sysdeps/unix/sysv/linux/signal.c: Use POSIX implementation. * sysdeps/unix/sysv/linux/statbuf.h: Define _STAT_VER. * sysdeps/unix/sysv/linux/i386/sigaction.c: Correct parameter name usage (new->act, old->oact). Correct asm statement because of gcc strangeness. * sysdeps/i386/i586/strchr.S: Correct typos: cmp -> cmpb. * sunrpc/clnt_perr.c: Remove declaration of sys_errlist. They conflict with the ones in stdio.h. * string/tester.c: %Z is no complete format. Change to %Zd. * sysdeps/mach/hurd/symlink.c (__symlink): Ditto.
Diffstat (limited to 'sysdeps/unix/sysv')
-rw-r--r-- | sysdeps/unix/sysv/linux/i386/sigaction.c | 47 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/poll.c | 2 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/signal.c | 1 | ||||
-rw-r--r-- | sysdeps/unix/sysv/linux/statbuf.h | 4 |
4 files changed, 31 insertions, 23 deletions
diff --git a/sysdeps/unix/sysv/linux/i386/sigaction.c b/sysdeps/unix/sysv/linux/i386/sigaction.c index 6986290da5..64c8f9a404 100644 --- a/sysdeps/unix/sysv/linux/i386/sigaction.c +++ b/sysdeps/unix/sysv/linux/i386/sigaction.c @@ -31,20 +31,20 @@ __sigaction (int sig, const struct sigaction *act, struct sigaction *oact) struct sigaction newact; int result; - if (new) + if (act) { - newact = *new; - new = &newact; - new->sa_restorer = ((new->sa_flags & SA_NOMASK) - ? &&restore_nomask : &&restore); + newact = *act; + newact.sa_restorer = ((act->sa_flags & SA_NOMASK) + ? &&restore_nomask : &&restore); + act = &newact; } asm volatile ("pushl %%ebx\n" - "movl %1, %%ebx\n" + "movl %2, %%ebx\n" "int $0x80\n" "popl %%ebx" : "=a" (result) - : "0" (SYS_ify (sigaction)), "g" (sig), "c" (new), "d" (old)); + : "0" (SYS_ify (sigaction)), "g" (sig), "c" (act), "d" (oact)); if (result < 0) { @@ -56,31 +56,34 @@ __sigaction (int sig, const struct sigaction *act, struct sigaction *oact) restore: asm ( #ifdef PIC - " pushl %ebx\n" + " pushl %%ebx\n" " call 0f\n" - "0: popl %ebx\n" - " addl $_GLOBAL_OFFSET_TABLE_+[.-0b],%ebx\n" + "0: popl %%ebx\n" + " addl $_GLOBAL_OFFSET_TABLE_+[.-0b], %%ebx\n" " addl $8, %%esp\n" " call __sigsetmask@PLT\n" " addl $8, %%esp\n" - " popl %ebx\n" + " popl %%ebx\n" #else " addl $4, %%esp\n" " call __sigsetmask\n" " addl $4, %%esp\n" #endif - "popl %eax\n" - "popl %ecx\n" - "popl %edx\n" - "popf\n" - "ret"); + " popl %%eax\n" + " popl %%ecx\n" + " popl %%edx\n" + " popf\n" + " ret" + : : ); restore_nomask: - asm ("addl $4, %esp\n" - "popl %eax\n" - "popl %ecx\n" - "popl %edx\n" - "popf\n" - "ret"); + asm (" addl $4, %%esp\n" + " popl %%eax\n" + " popl %%ecx\n" + " popl %%edx\n" + " popf\n" + " ret" + : : ); + /* NOTREACHED */ } weak_alias (__sigaction, sigaction) diff --git a/sysdeps/unix/sysv/linux/poll.c b/sysdeps/unix/sysv/linux/poll.c index ff43a76a63..198819970a 100644 --- a/sysdeps/unix/sysv/linux/poll.c +++ b/sysdeps/unix/sysv/linux/poll.c @@ -1 +1 @@ -#include <sysdeps/stub/poll.c> +#include <sysdeps/unix/bsd/poll.c> diff --git a/sysdeps/unix/sysv/linux/signal.c b/sysdeps/unix/sysv/linux/signal.c new file mode 100644 index 0000000000..55f1108498 --- /dev/null +++ b/sysdeps/unix/sysv/linux/signal.c @@ -0,0 +1 @@ +#include <sysdeps/posix/signal.c> diff --git a/sysdeps/unix/sysv/linux/statbuf.h b/sysdeps/unix/sysv/linux/statbuf.h index ad81704ae5..5aabdd30ad 100644 --- a/sysdeps/unix/sysv/linux/statbuf.h +++ b/sysdeps/unix/sysv/linux/statbuf.h @@ -19,6 +19,10 @@ Cambridge, MA 02139, USA. */ #ifndef _STATBUF_H #define _STATBUF_H +/* Current version of stat system call. */ +#define _STAT_VER 1 + + struct stat { short int st_dev; /* Device. */ |