11 May, 2007

1 commit


12 Feb, 2007

1 commit

  • I noticed that almost all architectures implemented exactly the same
    sys32_sysinfo... except parisc, where a bug was to be found in handling of
    the uptime. So let's remove a whole whack of code for fun and profit.
    Cribbed compat_sys_sysinfo from x86_64's implementation, since I figured it
    would be the best tested.

    This patch incorporates Arnd's suggestion of not using set_fs/get_fs, but
    instead extracting out the common code from sys_sysinfo.

    Cc: Christoph Hellwig
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kyle McMartin
     

04 Nov, 2006

1 commit


29 Oct, 2006

1 commit


02 Oct, 2006

1 commit

  • Revert Andrew Morton's patch to temporarily hack around the lack of a
    declaration of sigset_t in linux/compat.h to make the block-disablement
    patches build on IA64. This got accidentally pushed to Linus and should
    be fixed in a different manner.

    Also make linux/compat.h #include asm/signal.h to gain a definition of
    sigset_t so that it can externally declare sigset_from_compat().

    This has been compile-tested for i386, x86_64, ia64, mips, mips64, frv, ppc and
    ppc64 and run-tested on frv.

    Signed-off-by: David Howells
    Signed-off-by: Linus Torvalds

    David Howells
     

01 Oct, 2006

1 commit


30 Sep, 2006

1 commit

  • The clock_nanosleep() function does not return the time remaining when the
    sleep is interrupted by a signal.

    This patch creates a new call out, compat_clock_nanosleep_restart(), which
    handles returning the remaining time after a sleep is interrupted. This
    patch revives clock_nanosleep_restart(). It is now accessed via the new
    call out. The compat_clock_nanosleep_restart() is used for compatibility
    access.

    Since this is implemented in compatibility mode the normal path is
    virtually unaffected - no real performance impact.

    Signed-off-by: Toyo Abe
    Cc: Thomas Gleixner
    Cc: Ingo Molnar
    Cc: Roland McGrath
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Toyo Abe
     

26 Jun, 2006

1 commit

  • I'm testing glibc on MIPS64, little-endian, N32, O32 and N64 multilibs.

    Among the NPTL test failures seen are some arising from sigsuspend problems
    for N32: it blocks the wrong signals, so SIGCANCEL (SIGRTMIN) is blocked
    despite glibc's carefully excluding it from sets of signals to block.
    Specifically, testing suggests it blocks signal N^32 instead of signal N,
    so (in the example tested) blocking SIGUSR1 (17) blocks signal 49 instead.

    glibc's sigset_t uses an array of unsigned long, as does the kernel.
    In both cases, signal N+1 is represented as
    (1UL << (N % (8 * sizeof (unsigned long)))) in word number
    (N / (8 * sizeof (unsigned long))).

    Thus the N32 glibc uses an array of 32-bit words and the N64 kernel uses an
    array of 64-bit words. For little-endian, the layout is the same, with
    signals 1-32 in the first 4 bytes, signals 33-64 in the second, etc.; for
    big-endian, userspace has that layout while in the kernel each 8 bytes have
    the two halves swapped from the userspace layout.

    The N32 sigsuspend syscall uses sigset_from_compat to convert the userspace
    sigset to kernel format. If __COMPAT_ENDIAN_SWAP__ is *not* set, this uses
    logic of the form

    set->sig[0] = compat->sig[0] | (((long)compat->sig[1]) << 32 )

    to convert the userspace sigset to a kernel one. This looks correct to me
    for both big and little endian, given that in userspace compat->sig[1] will
    represent signals 33-64, and so will the high 32 bits of set->sig[0] in the
    kernel. If however __COMPAT_ENDIAN_SWAP__ *is* set, as it is for
    __MIPSEL__, it uses

    set->sig[0] = compat->sig[1] | (((long)compat->sig[0]) << 32 );

    which seems incorrect for both big and little endian, and would
    explain the observed symptoms.

    This code is the only use of __COMPAT_ENDIAN_SWAP__, so if incorrect
    then that macro serves no purpose, in which case something like the
    following patch would seem appropriate to remove it.

    Signed-off-by: Joseph Myers
    Signed-off-by: Ralf Baechle
    Cc: Arnd Bergmann
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    akpm@osdl.org
     

23 Jun, 2006

2 commits

  • The definition of the third parameter is a pointer to an array of virtual
    addresses which give us some trouble. The existing code calculated the
    wrong address in the array since I used void to avoid having to specify a
    type.

    I now use the correct type "compat_uptr_t __user *" in the definition of
    the function in kernel/compat.c.

    However, I used __u32 in syscalls.h. Would have to include compat.h there
    in order to provide the same definition which would generate an ugly
    include situation.

    On both ia64 and x86_64 compat_uptr_t is u32. So this works although
    parameter declarations differ.

    Signed-off-by: Christoph Lameter
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     
  • sys_move_pages() support for 32bit (i386 plus x86_64 compat layer)

    Add support for move_pages() on i386 and also add the compat functions
    necessary to run 32 bit binaries on x86_64.

    Add compat_sys_move_pages to the x86_64 32bit binary layer. Note that it is
    not up to date so I added the missing pieces. Not sure if this is done the
    right way.

    [akpm@osdl.org: compile fix]
    Signed-off-by: Christoph Lameter
    Cc: Andi Kleen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Lameter
     

28 Mar, 2006

1 commit

  • 32-bit syscall compatibility support. (This patch also moves all futex
    related compat functionality into kernel/futex_compat.c.)

    Signed-off-by: Ingo Molnar
    Signed-off-by: Thomas Gleixner
    Signed-off-by: Arjan van de Ven
    Acked-by: Ulrich Drepper
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ingo Molnar
     

27 Mar, 2006

1 commit


08 Feb, 2006

1 commit


19 Jan, 2006

1 commit

  • The TIF_RESTORE_SIGMASK flag allows us to have a generic implementation of
    sys_rt_sigsuspend() instead of duplicating it for each architecture. This
    provides such an implementation and makes arch/powerpc use it.

    It also tidies up the ppc32 sys_sigsuspend() to use TIF_RESTORE_SIGMASK.

    Signed-off-by: David Woodhouse
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Woodhouse
     

11 Jan, 2006

1 commit

  • The comment in compat.c is wrong, every architecture provides a
    get_compat_sigevent() for the IPC compat code already.

    This basically moves the x86_64 version to common code and removes all the
    others.

    Signed-off-by: Christoph Hellwig
    Acked-by: Paul Mackerras
    Cc: Arnd Bergmann
    Cc: Benjamin Herrenschmidt
    Cc: Martin Schwidefsky
    Cc: "David S. Miller"
    Acked-by: Andi Kleen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Christoph Hellwig
     

11 Sep, 2005

1 commit


17 Apr, 2005

2 commits

  • I have no idea how a bug like this lasted so long. Anyways, obvious
    memset()'ing of incorrect pointer.

    Signed-off-by: David S. Miller
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David S. Miller
     
  • Initial git repository build. I'm not bothering with the full history,
    even though we have it. We can create a separate "historical" git
    archive of that later if we want to, and in the meantime it's about
    3.2GB when imported into git - space that would just make the early
    git days unnecessarily complicated, when we don't have a lot of good
    infrastructure for it.

    Let it rip!

    Linus Torvalds