From: Olaf Kirch <okir@suse.de>
To: nfs@lists.sourceforge.net, akpm@osdl.org
Subject: [PATCH] NFS nolock broken in 2.6.9-rc4
Date: Fri, 15 Oct 2004 11:58:40 +0200 [thread overview]
Message-ID: <20041015095840.GA22992@suse.de> (raw)
Hi,
2.6.9-rc2 and later contain the following hunks in fs/locks.c:
@@ -1489,8 +1534,7 @@ int fcntl_setlk(struct file *filp, unsig
if (filp->f_op && filp->f_op->lock != NULL) {
error = filp->f_op->lock(filp, cmd, file_lock);
- if (error < 0)
- goto out;
+ goto out;
}
for (;;) {
@@ -1624,8 +1668,7 @@ int fcntl_setlk64(struct file *filp, uns
if (filp->f_op && filp->f_op->lock != NULL) {
error = filp->f_op->lock(filp, cmd, file_lock);
- if (error < 0)
- goto out;
+ goto out;
}
for (;;) {
For an NFS file system mounted with -o nolock, this means filp->f_op->lock
will return 0 but do nothing. Previously, this would cause local locking
to be used. With the change above, we just return.
I don't know why this change was made. The patch below simply reverts
these two hunks; maybe there's a better solution involving LOCK_USE_CLNT
the way it's used for F_GETLK at the moment.
Olaf
--
Olaf Kirch | Things that make Monday morning interesting, #1:
okir@suse.de | "I want to use NFS over AX25, can you help me?"
---------------+
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
NFS maillist - NFS@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nfs
next reply other threads:[~2004-10-15 10:00 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-10-15 9:58 Olaf Kirch [this message]
2004-10-15 10:07 ` [PATCH] NFS nolock broken in 2.6.9-rc4 Olaf Kirch
2004-10-15 14:46 ` Trond Myklebust
2004-10-15 15:11 ` Trond Myklebust
2004-10-15 15:13 ` Trond Myklebust
[not found] ` <20041016004957.38ccd273.akpm@osdl.org>
2004-10-18 7:39 ` Olaf Kirch
2004-10-15 14:44 ` Trond Myklebust
2004-10-15 15:12 ` Olaf Kirch
2004-10-15 15:21 ` Olaf Kirch
2004-10-15 16:47 ` Trond Myklebust
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20041015095840.GA22992@suse.de \
--to=okir@suse.de \
--cc=akpm@osdl.org \
--cc=nfs@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.