OpenAFS Master Repository branch, openafs-stable-1_6_x, updated. openafs-stable-1_6_0pre2-86-gde478ca

Gerrit Code Review gerrit@openafs.org
Mon, 14 Mar 2011 20:54:47 -0700 (PDT)


The following commit has been merged in the openafs-stable-1_6_x branch:
commit de478ca8ac14b991082bf0f26fb9807a913980a0
Author: Simon Wilkinson <sxw@your-file-system.com>
Date:   Tue Mar 15 00:06:19 2011 +0000

    Revert "Linux: normalize error return for emulated syscalls"
    
    This reverts commit 0bc837f68a72ba1f75d940cc5dd057774d9f36bb.
    
    Sadly, this change fixed setpag(), but broke all of the pioctls. The
    problem is actually a little more nuanced than we at first thought.
    What's happening is yet another case of Linux's special handling of
    negative return values. When an ioctl handler returns a negative
    return code to the kernel, it does errno = -code, and sets the
    return code to -1. If you pass it a postive return code, however,
    it just returns that straight to the application.
    
    The pioctl code gets this right. However, the setpag code doesn't,
    and so tries to return postive values, which is why ioctl appears
    to be returning the error code in the return value, not in the
    errno.
    
    Reviewed-on: http://gerrit.openafs.org/4222
    Tested-by: BuildBot <buildbot@rampaginggeek.com>
    Tested-by: Marc Dionne <marc.c.dionne@gmail.com>
    Reviewed-by: Marc Dionne <marc.c.dionne@gmail.com>
    Reviewed-by: Derrick Brashear <shadow@dementia.org>
    (cherry picked from commit ff2933a122ddf9421ebcacdc7e4ec5f44333f894)
    
    Change-Id: Ibfb050552f8b2357e57139976e2bc42ce6187f4f
    Reviewed-on: http://gerrit.openafs.org/4225
    Tested-by: BuildBot <buildbot@rampaginggeek.com>
    Reviewed-by: Derrick Brashear <shadow@dementia.org>
    Tested-by: Derrick Brashear <shadow@dementia.org>

 src/sys/glue.c |   34 ++++++++++++++--------------------
 1 files changed, 14 insertions(+), 20 deletions(-)

-- 
OpenAFS Master Repository