From: Steven Whitehouse <swhiteho@redhat.com>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] [GFS2 PATCH] bz502531 - GFS2: smbd proccess hangs with flock() call.
Date: Tue, 02 Jun 2009 09:08:52 +0100 [thread overview]
Message-ID: <1243930132.29604.547.camel@localhost.localdomain> (raw)
In-Reply-To: <4A24101B.5020301@redhat.com>
Hi,
Now applied to the -nmw git tree. Thanks,
Steve.
On Mon, 2009-06-01 at 12:30 -0500, Abhijith Das wrote:
> GFS2 currently does not support mandatory flocks. An flock() call with
> LOCK_MAND triggers unexpected behavior because gfs2 is not checking for
> this lock type. This patch corrects that.
>
> Signed-off-by: Abhi Das <adas@redhat.com>
> plain text document attachment (bz502531-git.patch)
> diff --git a/fs/gfs2/file.c b/fs/gfs2/file.c
> index 73b6f55..841ddc9 100644
> --- a/fs/gfs2/file.c
> +++ b/fs/gfs2/file.c
> @@ -698,8 +698,8 @@ static int gfs2_flock(struct file *file, int cmd, struct file_lock *fl)
>
> if (!(fl->fl_flags & FL_FLOCK))
> return -ENOLCK;
> - if (__mandatory_lock(&ip->i_inode))
> - return -ENOLCK;
> + if (fl->fl_type & LOCK_MAND)
> + return -EOPNOTSUPP;
>
> if (fl->fl_type == F_UNLCK) {
> do_unflock(file, fl);
prev parent reply other threads:[~2009-06-02 8:08 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-29 19:11 [Cluster-devel] GFS2: Add tracepoints Steven Whitehouse
2009-05-29 19:23 ` [Cluster-devel] " Christoph Hellwig
2009-05-29 19:50 ` Steven Whitehouse
2009-05-30 10:25 ` Christoph Hellwig
2009-06-01 14:19 ` Steven Whitehouse
2009-06-01 17:30 ` [Cluster-devel] [GFS2 PATCH] bz502531 - GFS2: smbd proccess hangs with flock() call Abhijith Das
2009-06-02 8:08 ` Steven Whitehouse [this message]
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=1243930132.29604.547.camel@localhost.localdomain \
--to=swhiteho@redhat.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox