unified (weak) sys_pipe implementation
authorUlrich Drepper <drepper@redhat.com>
Sat, 3 May 2008 19:10:37 +0000 (15:10 -0400)
committerLinus Torvalds <torvalds@linux-foundation.org>
Sat, 3 May 2008 20:50:33 +0000 (13:50 -0700)
commitd35c7b0e54a596c5a8134d75999b7f391a9c6550
tree697bb89dbeccae28eb928b2589f500d747ed38ec
parent2ddcca36c8bcfa251724fe342c8327451988be0d
unified (weak) sys_pipe implementation

This replaces the duplicated arch-specific versions of "sys_pipe()" with
one unified implementation.  This removes almost 250 lines of duplicated
code.

It's marked __weak, so that *if* an architecture wants to override the
default implementation it can do so by simply having its own replacement
version, since many architectures use alternate calling conventions for
the 'pipe()' system call for legacy reasons (ie traditional UNIX
implementations often return the two file descriptors in registers)

I still haven't changed the cris version even though Linus says the BKL
isn't needed.  The arch maintainer can easily do it if there are really
no obstacles.

Signed-off-by: Ulrich Drepper <drepper@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
18 files changed:
arch/arm/kernel/sys_arm.c
arch/avr32/kernel/sys_avr32.c
arch/blackfin/kernel/sys_bfin.c
arch/frv/kernel/sys_frv.c
arch/h8300/kernel/sys_h8300.c
arch/m68k/kernel/sys_m68k.c
arch/m68knommu/kernel/sys_m68k.c
arch/mn10300/kernel/sys_mn10300.c
arch/parisc/kernel/sys_parisc.c
arch/powerpc/kernel/syscalls.c
arch/s390/kernel/sys_s390.c
arch/sh/kernel/sys_sh64.c
arch/um/kernel/syscall.c
arch/v850/kernel/syscalls.c
arch/x86/kernel/sys_i386_32.c
arch/x86/kernel/sys_x86_64.c
fs/pipe.c
include/asm-powerpc/syscalls.h