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] [GFS2 PATCH] [TRY #2] GFS2: inline function gfs2_set_mode
Date: Wed, 19 Mar 2014 16:17:18 +0000	[thread overview]
Message-ID: <1395245838.2749.12.camel@menhir> (raw)
In-Reply-To: <1954729983.2102259.1395244288643.JavaMail.zimbra@redhat.com>

Hi,
On Wed, 2014-03-19 at 11:51 -0400, Bob Peterson wrote:
> Hi,
> 
> Here is a revised patch based on Steve's feedback:
> 
> This patch eliminates function gfs2_set_mode which was only called in
> one place, and always returned 0.
> 
Now in the -nmw tree. Thanks,

Steve.

> Regards,
> 
> Bob Peterson
> Red Hat File Systems
> 
> Signed-off-by: Bob Peterson <rpeterso@redhat.com>
> ---
> diff --git a/fs/gfs2/acl.c b/fs/gfs2/acl.c
> index 394dc55..3088e2a 100644
> --- a/fs/gfs2/acl.c
> +++ b/fs/gfs2/acl.c
> @@ -64,18 +64,6 @@ struct posix_acl *gfs2_get_acl(struct inode *inode, int type)
>  	return acl;
>  }
>  
> -static int gfs2_set_mode(struct inode *inode, umode_t mode)
> -{
> -	int error = 0;
> -
> -	if (mode != inode->i_mode) {
> -		inode->i_mode = mode;
> -		mark_inode_dirty(inode);
> -	}
> -
> -	return error;
> -}
> -
>  int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type)
>  {
>  	int error;
> @@ -98,9 +86,10 @@ int gfs2_set_acl(struct inode *inode, struct posix_acl *acl, int type)
>  		if (error == 0)
>  			acl = NULL;
>  
> -		error = gfs2_set_mode(inode, mode);
> -		if (error)
> -			return error;
> +		if (mode != inode->i_mode) {
> +			inode->i_mode = mode;
> +			mark_inode_dirty(inode);
> +		}
>  	}
>  
>  	if (acl) {
> 




      reply	other threads:[~2014-03-19 16:17 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1834202248.2101300.1395244186633.JavaMail.zimbra@redhat.com>
2014-03-19 15:51 ` [Cluster-devel] [GFS2 PATCH] [TRY #2] GFS2: inline function gfs2_set_mode Bob Peterson
2014-03-19 16:17   ` 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=1395245838.2749.12.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).