All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch-jcswGhMUV9g@public.gmane.org>
To: "J. Bruce Fields" <bfields-uC3wQj2KruNg9hUCZPvPmw@public.gmane.org>
Cc: Christoph Hellwig <hch-jcswGhMUV9g@public.gmane.org>,
	viro-RmSDqhL/yNMiFSDQTTA3OLVCufUGDwFn@public.gmane.org,
	tao.peng-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org,
	jeff.layton-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org,
	linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-btrfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-nfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 2/5] locks: new locks_mandatory_area calling convention
Date: Tue, 1 Dec 2015 08:37:18 +0100	[thread overview]
Message-ID: <20151201073718.GA29495@lst.de> (raw)
In-Reply-To: <20151130223830.GB31564-uC3wQj2KruNg9hUCZPvPmw@public.gmane.org>

On Mon, Nov 30, 2015 at 05:38:30PM -0500, J. Bruce Fields wrote:
> > +	if (size < inode->i_size) {
> > +		return locks_mandatory_area(filp, size, inode->i_size - 1,
> > +				true);
> > +	} else {
> > +		return locks_mandatory_area(filp, inode->i_size, size - 1,
> > +				true);
> 
> I feel like these callers would be just slightly more self-documenting
> if that last parameter was F_WRLCK instead of true.

Sure, I can change that forthe next version.

WARNING: multiple messages have this Message-ID (diff)
From: Christoph Hellwig <hch@lst.de>
To: "J. Bruce Fields" <bfields@fieldses.org>
Cc: Christoph Hellwig <hch@lst.de>,
	viro@zeniv.linux.org.uk, tao.peng@primarydata.com,
	jeff.layton@primarydata.com, linux-fsdevel@vger.kernel.org,
	linux-btrfs@vger.kernel.org, linux-nfs@vger.kernel.org,
	linux-cifs@vger.kernel.org
Subject: Re: [PATCH 2/5] locks: new locks_mandatory_area calling convention
Date: Tue, 1 Dec 2015 08:37:18 +0100	[thread overview]
Message-ID: <20151201073718.GA29495@lst.de> (raw)
In-Reply-To: <20151130223830.GB31564@fieldses.org>

On Mon, Nov 30, 2015 at 05:38:30PM -0500, J. Bruce Fields wrote:
> > +	if (size < inode->i_size) {
> > +		return locks_mandatory_area(filp, size, inode->i_size - 1,
> > +				true);
> > +	} else {
> > +		return locks_mandatory_area(filp, inode->i_size, size - 1,
> > +				true);
> 
> I feel like these callers would be just slightly more self-documenting
> if that last parameter was F_WRLCK instead of true.

Sure, I can change that forthe next version.


  parent reply	other threads:[~2015-12-01  7:37 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-26 18:50 vfs: move btrfs clone ioctls to common code Christoph Hellwig
2015-11-26 18:50 ` Christoph Hellwig
2015-11-26 18:50 ` [PATCH 2/5] locks: new locks_mandatory_area calling convention Christoph Hellwig
     [not found]   ` <1448563859-21922-3-git-send-email-hch-jcswGhMUV9g@public.gmane.org>
2015-11-30 22:38     ` J. Bruce Fields
2015-11-30 22:38       ` J. Bruce Fields
     [not found]       ` <20151130223830.GB31564-uC3wQj2KruNg9hUCZPvPmw@public.gmane.org>
2015-12-01  7:37         ` Christoph Hellwig [this message]
2015-12-01  7:37           ` Christoph Hellwig
2015-11-26 18:50 ` [PATCH 3/5] vfs: pull btrfs clone API to vfs layer Christoph Hellwig
2015-11-26 18:50 ` [PATCH 4/5] nfsd: Pass filehandle to nfs4_preprocess_stateid_op() Christoph Hellwig
     [not found] ` <1448563859-21922-1-git-send-email-hch-jcswGhMUV9g@public.gmane.org>
2015-11-26 18:50   ` [PATCH 1/5] cifs: implement clone_file_range operation Christoph Hellwig
2015-11-26 18:50     ` Christoph Hellwig
     [not found]     ` <1448563859-21922-2-git-send-email-hch-jcswGhMUV9g@public.gmane.org>
2015-11-27 10:42       ` David Disseldorp
2015-11-27 10:42         ` David Disseldorp
     [not found]         ` <20151127114232.5b367b7b-TzLh5lQYVSQb1SvskN2V4Q@public.gmane.org>
2015-11-30  9:02           ` Christoph Hellwig
2015-11-30  9:02             ` Christoph Hellwig
2015-11-26 18:50   ` [PATCH 5/5] nfsd: implement the NFSv4.2 CLONE operation Christoph Hellwig
2015-11-26 18:50     ` Christoph Hellwig
2015-11-30 22:56   ` vfs: move btrfs clone ioctls to common code J. Bruce Fields
2015-11-30 22:56     ` J. Bruce Fields
2015-12-01 17:09   ` Chris Mason
2015-12-01 17:09     ` Chris Mason
2015-12-01 22:48   ` Steve French
2015-12-01 22:48     ` Steve French
2015-12-02  7:27     ` Christoph Hellwig
     [not found]       ` <20151202072757.GB15839-jcswGhMUV9g@public.gmane.org>
2015-12-02 17:40         ` Steve French
2015-12-02 17:40           ` Steve French
2015-12-03 10:30           ` Christoph Hellwig
     [not found]             ` <20151203103035.GA15996-jcswGhMUV9g@public.gmane.org>
2015-12-03 19:28               ` Steve French
2015-12-03 19:28                 ` Steve French

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=20151201073718.GA29495@lst.de \
    --to=hch-jcswghmuv9g@public.gmane.org \
    --cc=bfields-uC3wQj2KruNg9hUCZPvPmw@public.gmane.org \
    --cc=jeff.layton-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org \
    --cc=linux-btrfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-cifs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-nfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=tao.peng-7I+n7zu2hftEKMMhf/gKZA@public.gmane.org \
    --cc=viro-RmSDqhL/yNMiFSDQTTA3OLVCufUGDwFn@public.gmane.org \
    /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.