All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dave Quigley <dpquigl@davequigley.com>
To: Steve Dickson <SteveD@redhat.com>
Cc: "Myklebust, Trond" <Trond.Myklebust@netapp.com>,
	Julia Lawall <Julia.Lawall@lip6.fr>,
	"kernel-janitors@vger.kernel.org"
	<kernel-janitors@vger.kernel.org>,
	"linux-nfs@vger.kernel.org" <linux-nfs@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] fs/nfs/inode.c: adjust code alignment
Date: Wed, 07 Aug 2013 01:58:15 +0000	[thread overview]
Message-ID: <5201A9B7.1010605@davequigley.com> (raw)
In-Reply-To: <52013A9D.4010905@RedHat.com>

On 8/6/2013 2:04 PM, Steve Dickson wrote:
> Hello,
>
> On 05/08/13 10:59, Myklebust, Trond wrote:
>> On Mon, 2013-08-05 at 16:47 +0200, Julia Lawall wrote:
>>> From: Julia Lawall <Julia.Lawall@lip6.fr>
>>>
>>> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
>>>
>>> ---
>>>
>>> This patch adjusts the code so that the alignment matches the current
>>> semantics.  I have no idea if it is the intended semantics, though.  Should
>>> the call to nfs_setsecurity also be under the else?
>>>
>>
>>>   fs/nfs/inode.c |    2 +-
>>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
>>> index af6e806..d8ad685 100644
>>> --- a/fs/nfs/inode.c
>>> +++ b/fs/nfs/inode.c
>>> @@ -463,7 +463,7 @@ nfs_fhget(struct super_block *sb, struct nfs_fh
>>> *fh, struct nfs_fattr *fattr, st
>>>                  unlock_new_inode(inode);
>>>          } else
>>>                  nfs_refresh_inode(inode, fattr);
>>> -               nfs_setsecurity(inode, fattr, label);
>>> +       nfs_setsecurity(inode, fattr, label);
> This call to nfs_setsecurity() is not needed. The security only needs
> to be set when the i-node is created...
>
> steved.
>
>>>          dprintk("NFS: nfs_fhget(%s/%Ld fh_crc=0x%08x ct=%d)\n",
>>>                  inode->i_sb->s_id,
>>>                  (long long)NFS_FILEID(inode),
>>
>> Hi Julia,
>>
>> Thanks for pointing this out! Given that the 'then' clause of the if
>> statement already calls nfs_setsecurity before unlocking the inode, I
>> suspect that the above _should_ really be part of the 'else' clause.
>>
>> That said, I can't see that calling nfs_setsecurity twice on the inode
>> can cause any unintended side-effects, so I suggest that we rather queue
>> the patch up for inclusion in 3.12.
>> Steve and Dave, any comments?
>>
>

I can't see why it would be needed either. I agree with Steve. We can 
get rid of it.

Dave

WARNING: multiple messages have this Message-ID (diff)
From: Dave Quigley <dpquigl@davequigley.com>
To: Steve Dickson <SteveD@redhat.com>
Cc: "Myklebust, Trond" <Trond.Myklebust@netapp.com>,
	Julia Lawall <Julia.Lawall@lip6.fr>,
	"kernel-janitors@vger.kernel.org"
	<kernel-janitors@vger.kernel.org>,
	"linux-nfs@vger.kernel.org" <linux-nfs@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] fs/nfs/inode.c: adjust code alignment
Date: Tue, 06 Aug 2013 21:58:15 -0400	[thread overview]
Message-ID: <5201A9B7.1010605@davequigley.com> (raw)
In-Reply-To: <52013A9D.4010905@RedHat.com>

On 8/6/2013 2:04 PM, Steve Dickson wrote:
> Hello,
>
> On 05/08/13 10:59, Myklebust, Trond wrote:
>> On Mon, 2013-08-05 at 16:47 +0200, Julia Lawall wrote:
>>> From: Julia Lawall <Julia.Lawall@lip6.fr>
>>>
>>> Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
>>>
>>> ---
>>>
>>> This patch adjusts the code so that the alignment matches the current
>>> semantics.  I have no idea if it is the intended semantics, though.  Should
>>> the call to nfs_setsecurity also be under the else?
>>>
>>
>>>   fs/nfs/inode.c |    2 +-
>>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/fs/nfs/inode.c b/fs/nfs/inode.c
>>> index af6e806..d8ad685 100644
>>> --- a/fs/nfs/inode.c
>>> +++ b/fs/nfs/inode.c
>>> @@ -463,7 +463,7 @@ nfs_fhget(struct super_block *sb, struct nfs_fh
>>> *fh, struct nfs_fattr *fattr, st
>>>                  unlock_new_inode(inode);
>>>          } else
>>>                  nfs_refresh_inode(inode, fattr);
>>> -               nfs_setsecurity(inode, fattr, label);
>>> +       nfs_setsecurity(inode, fattr, label);
> This call to nfs_setsecurity() is not needed. The security only needs
> to be set when the i-node is created...
>
> steved.
>
>>>          dprintk("NFS: nfs_fhget(%s/%Ld fh_crc=0x%08x ct=%d)\n",
>>>                  inode->i_sb->s_id,
>>>                  (long long)NFS_FILEID(inode),
>>
>> Hi Julia,
>>
>> Thanks for pointing this out! Given that the 'then' clause of the if
>> statement already calls nfs_setsecurity before unlocking the inode, I
>> suspect that the above _should_ really be part of the 'else' clause.
>>
>> That said, I can't see that calling nfs_setsecurity twice on the inode
>> can cause any unintended side-effects, so I suggest that we rather queue
>> the patch up for inclusion in 3.12.
>> Steve and Dave, any comments?
>>
>

I can't see why it would be needed either. I agree with Steve. We can 
get rid of it.

Dave

  reply	other threads:[~2013-08-07  1:58 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-05 14:47 [PATCH] adjust code alignment Julia Lawall
2013-08-05 14:47 ` Julia Lawall
2013-08-05 14:47 ` [PATCH] fs/nfs/inode.c: " Julia Lawall
2013-08-05 14:47   ` Julia Lawall
2013-08-05 14:59   ` Myklebust, Trond
2013-08-05 14:59     ` Myklebust, Trond
2013-08-05 14:59     ` Myklebust, Trond
2013-08-06 18:04     ` Steve Dickson
2013-08-06 18:04       ` Steve Dickson
2013-08-07  1:58       ` Dave Quigley [this message]
2013-08-07  1:58         ` Dave Quigley
2013-08-05 14:47 ` [PATCH] drivers/scsi/lpfc/lpfc_init.c: " Julia Lawall
2013-08-05 14:47   ` Julia Lawall
2013-08-05 14:47 ` [PATCH] net/vmw_vsock/af_vsock.c: drop unneeded semicolon Julia Lawall
2013-08-05 14:47   ` Julia Lawall
2013-08-05 18:08   ` David Miller
2013-08-05 18:08     ` David Miller
2013-08-05 14:47 ` [PATCH] trivial: adjust code alignment Julia Lawall
2013-08-05 14:47   ` Julia Lawall
2013-08-05 16:06   ` Dan Carpenter
2013-08-05 16:06     ` Dan Carpenter
2013-08-05 16:17     ` Joe Perches
2013-08-05 16:17       ` Joe Perches
2013-08-05 16:30       ` Dan Carpenter
2013-08-05 16:30         ` Dan Carpenter
2013-08-06  0:51         ` Joe Perches
2013-08-06  0:51           ` Joe Perches
2013-08-05 16:19     ` Julia Lawall
2013-08-05 16:19       ` Julia Lawall
2013-08-05 16:24       ` walter harms
2013-08-05 16:24         ` walter harms
2013-08-05 16:28         ` Julia Lawall
2013-08-05 16:28           ` Julia Lawall
2013-08-05 17:05         ` Dan Carpenter
2013-08-05 17:05           ` Dan Carpenter
2013-08-05 16:52       ` Jonathan Corbet
2013-08-05 16:52         ` Jonathan Corbet

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=5201A9B7.1010605@davequigley.com \
    --to=dpquigl@davequigley.com \
    --cc=Julia.Lawall@lip6.fr \
    --cc=SteveD@redhat.com \
    --cc=Trond.Myklebust@netapp.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-nfs@vger.kernel.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.