OpenAFS Master Repository branch, openafs-stable-1_6_x, updated. openafs-stable-1_6_8-151-g54c6178

Gerrit Code Review gerrit@openafs.org
Wed, 13 Aug 2014 11:30:29 -0400


The following commit has been merged in the openafs-stable-1_6_x branch:
commit 54c61781e2a1e59e9bfbd5cc065d9fef0c6f83a0
Author: Andrew Deason <adeason@sinenomine.net>
Date:   Thu Jul 17 10:33:23 2014 -0500

    LINUX: Avoid premature RO volume lock error
    
    Commit 0fc27471e7da0c5de4addcdec1bfbca5208072cc avoids processing lock
    requests for RO volumes, but it did this both in afs_lockctl() and in
    the Linux-specific afs_linux_lock(). The changes in afs_linux_lock()
    are incorrect, since they also avoid F_GETLK requests (whereas
    afs_lockctl() just avoids F_SETLK* requests).
    
    Additionally, the section in afs_linux_lock() incorrectly reports an
    error, since it returns a positive EBADF error code, when we are
    supposed to return -EBADF.
    
    The result of all of this is that an F_GETLK F_WRLCK request for an RO
    volume always fails with fcntl() returning 9 (EBADF), which is an
    invalid return code for fcntl() F_GETLK (instead we should return -1
    with an errno of 9). But if there are no locks, we should return
    success anyway.
    
    Just remove this section, since afs_lockctl() handles this case itself
    anyway.
    
    Thanks to Todd Lewis for reporting this issue.
    
    Reviewed-on: http://gerrit.openafs.org/11316
    Reviewed-by: Marc Dionne <marc.c.dionne@gmail.com>
    Reviewed-by: D Brashear <shadow@your-file-system.com>
    Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
    Tested-by: BuildBot <buildbot@rampaginggeek.com>
    (cherry picked from commit e0d0e6ffdbb11d5445b129ef0bd5030aec59d333)
    
    Change-Id: Ia5d03e55f7bad9f5678cdb82808b56d975865438
    Reviewed-on: http://gerrit.openafs.org/11361
    Reviewed-by: Chas Williams - CONTRACTOR <chas@cmf.nrl.navy.mil>
    Tested-by: BuildBot <buildbot@rampaginggeek.com>
    Reviewed-by: Andrew Deason <adeason@sinenomine.net>
    Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
    Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>

 src/afs/LINUX/osi_vnodeops.c |   10 ----------
 1 files changed, 0 insertions(+), 10 deletions(-)

-- 
OpenAFS Master Repository