You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
Merge branch 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6
* 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6: SUNRPC: Fix potential race in put_rpccred() SUNRPC: Fix rpcauth_prune_expired NFS: Convert nfs_attr_generation_counter into an atomic_long SUNRPC: Respond promptly to server TCP resets
This commit is contained in:
+3
-8
@@ -908,21 +908,16 @@ static int nfs_size_need_update(const struct inode *inode, const struct nfs_fatt
|
||||
return nfs_size_to_loff_t(fattr->size) > i_size_read(inode);
|
||||
}
|
||||
|
||||
static unsigned long nfs_attr_generation_counter;
|
||||
static atomic_long_t nfs_attr_generation_counter;
|
||||
|
||||
static unsigned long nfs_read_attr_generation_counter(void)
|
||||
{
|
||||
smp_rmb();
|
||||
return nfs_attr_generation_counter;
|
||||
return atomic_long_read(&nfs_attr_generation_counter);
|
||||
}
|
||||
|
||||
unsigned long nfs_inc_attr_generation_counter(void)
|
||||
{
|
||||
unsigned long ret;
|
||||
smp_rmb();
|
||||
ret = ++nfs_attr_generation_counter;
|
||||
smp_wmb();
|
||||
return ret;
|
||||
return atomic_long_inc_return(&nfs_attr_generation_counter);
|
||||
}
|
||||
|
||||
void nfs_fattr_init(struct nfs_fattr *fattr)
|
||||
|
||||
Reference in New Issue
Block a user