linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Al Viro <viro@ZenIV.linux.org.uk>
To: NeilBrown <neilb@suse.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	linux-fsdevel@vger.kernel.org, linux-nfs@vger.kernel.org,
	Amir Goldstein <amir73il@gmail.com>,
	lkml <linux-kernel@vger.kernel.org>,
	Lennart Poettering <lennart@poettering.net>
Subject: Re: [PATCH 1/4] fs/notify: fdinfo can report unsupported file handles.
Date: Mon, 11 Dec 2017 06:29:47 +0000	[thread overview]
Message-ID: <20171211062946.GX21978@ZenIV.linux.org.uk> (raw)
In-Reply-To: <151297224512.7818.18333908109878259066.stgit@noble>

On Mon, Dec 11, 2017 at 05:04:05PM +1100, NeilBrown wrote:
> @@ -385,7 +385,9 @@ int exportfs_encode_inode_fh(struct inode *inode, struct fid *fid,
>  {
>  	const struct export_operations *nop = inode->i_sb->s_export_op;
>  
> -	if (nop && nop->encode_fh)
> +	if (nop)
> +		return FILEID_INVALID;
> +	if (nop->encode_fh)
>  		return nop->encode_fh(inode, fid->raw, max_len, parent);

This might as well have been

	if (nop)
		return FILEID_INVALID;
	BUG();

Have you ever tested that?

  reply	other threads:[~2017-12-11  6:29 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-12-11  6:04 [PATCH 0/4] VFS: fix assorted issues with name_to_handle conversions NeilBrown
2017-12-11  6:04 ` [PATCH 4/4] fhandle: Improve error responses in name_to_handle_at() NeilBrown
2017-12-11 16:08   ` J. Bruce Fields
2017-12-11  6:04 ` [PATCH 2/4] fs/notify: don't put file handle buffer on stack NeilBrown
2017-12-11  6:47   ` Amir Goldstein
2017-12-11  6:04 ` [PATCH 3/4] NFS: allow name_to_handle_at() to work for Amazon EFS NeilBrown
2017-12-11  6:04 ` [PATCH 1/4] fs/notify: fdinfo can report unsupported file handles NeilBrown
2017-12-11  6:29   ` Al Viro [this message]
2017-12-11 22:12     ` NeilBrown
2017-12-11  6:41   ` Amir Goldstein
2017-12-11  7:05     ` Amir Goldstein
2017-12-11 13:46       ` Pavel Emelyanov
2017-12-11 14:08         ` Amir Goldstein
2017-12-11 15:21           ` Pavel Emelyanov
2017-12-11 21:52     ` NeilBrown
2017-12-12  6:39       ` Amir Goldstein
2017-12-13  2:20         ` NeilBrown

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=20171211062946.GX21978@ZenIV.linux.org.uk \
    --to=viro@zeniv.linux.org.uk \
    --cc=amir73il@gmail.com \
    --cc=lennart@poettering.net \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nfs@vger.kernel.org \
    --cc=neilb@suse.com \
    --cc=torvalds@linux-foundation.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).