Re: locking around modifications to i_nlink

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 27.07.2012, at 21:57, Jeff Layton <jlayton@xxxxxxxxxx> wrote:

> On Fri, 27 Jul 2012 11:48:39 -0500
> Steve French <smfrench@xxxxxxxxx> wrote:
> 
>> Presumably to address the cifs equivalent of NFS bug (drop_nlink warning):
>> 
>> https://bugzilla.redhat.com/show_bug.cgi?id=822703
>> 
>> your patch which wraps drop_nlink in i_lock spinlock (as Jeff noted
>> addresses only part of the problem)
>> http://git.altlinux.org/people/piastry/public/cifs-2.6.git?p=cifs-2.6.git;a=patch;h=df2d6b1fbf2401c5ee04f2ac143ea0954e3a87a6
>> 
>> shouldn't it also wrap the three places in fs/cifs/inode.c which do set_nlink?
>> 
> 
> It might not hurt to serialize all inode attribute updates under the
> i_lock. If two updates are racing and the CPU ends up reording things,
> you could end up with an inode that has a mix of attrs returned by
> calls. The NFS client did this quite some time ago...
> 
> -- 
> Jeff Layton <jlayton@xxxxxxxxxx>

Ok. I agree with your points. Since I am on vacations now I suggest to drop this patch from the series - I will respin it further. So, let's not stop on this one.--
To unsubscribe from this list: send the line "unsubscribe linux-cifs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux