cluster-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Steven Whitehouse <swhiteho@redhat.com>
To: cluster-devel.redhat.com
Subject: [Cluster-devel] [PATCH] GFS2: minor readability improvement in gfs2_mount()
Date: Thu, 06 Jun 2013 10:24:42 +0100	[thread overview]
Message-ID: <1370510682.2744.5.camel@menhir> (raw)
In-Reply-To: <1370467772-4587-1-git-send-email-khoroshilov@ispras.ru>

Hi,

On Thu, 2013-06-06 at 01:29 +0400, Alexey Khoroshilov wrote:
> The patch makes usage pattern of IS_ERR-PTR_ERR more typical.
> 
> Signed-off-by: Alexey Khoroshilov <khoroshilov@ispras.ru>
> ---
>  fs/gfs2/ops_fstype.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/fs/gfs2/ops_fstype.c b/fs/gfs2/ops_fstype.c
> index 0262c19..0d30e8e 100644
> --- a/fs/gfs2/ops_fstype.c
> +++ b/fs/gfs2/ops_fstype.c
> @@ -1313,9 +1313,10 @@ static struct dentry *gfs2_mount(struct file_system_type *fs_type, int flags,
>  	}
>  	s = sget(fs_type, test_gfs2_super, set_gfs2_super, flags, bdev);
>  	mutex_unlock(&bdev->bd_fsfreeze_mutex);
> -	error = PTR_ERR(s);
> -	if (IS_ERR(s))
> +	if (IS_ERR(s)) {
> +		error = PTR_ERR(s);
>  		goto error_bdev;
> +	}
I'm not sure what you are getting at here. Why add a jump into the fast
path?

Steve.

>  
>  	if (s->s_root)
>  		blkdev_put(bdev, mode);




  reply	other threads:[~2013-06-06  9:24 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-05 21:29 [Cluster-devel] [PATCH] GFS2: minor readability improvement in gfs2_mount() Alexey Khoroshilov
2013-06-06  9:24 ` Steven Whitehouse [this message]
2013-06-07  6:49   ` Alexey Khoroshilov
2013-06-10 11:04     ` Steven Whitehouse

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=1370510682.2744.5.camel@menhir \
    --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;
as well as URLs for NNTP newsgroup(s).