OpenAFS Master Repository branch, master, updated. openafs-devel-1_5_76-4320-ge0d0e6f
Gerrit Code Review
gerrit@openafs.org
Wed, 6 Aug 2014 12:56:15 -0400
The following commit has been merged in the master branch:
commit e0d0e6ffdbb11d5445b129ef0bd5030aec59d333
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.
Change-Id: Ia7f3f0b1bdbb922dca06be9de02a9c2b33f9ffee
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>
src/afs/LINUX/osi_vnodeops.c | 10 ----------
1 files changed, 0 insertions(+), 10 deletions(-)
--
OpenAFS Master Repository