mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
locks: break delegations on any attribute modification
NFSv4 uses leases to guarantee that clients can cache metadata as well as data. Cc: Mikulas Patocka <[email protected]> Cc: David Howells <[email protected]> Cc: Tyler Hicks <[email protected]> Cc: Dustin Kirkland <[email protected]> Acked-by: Jeff Layton <[email protected]> Signed-off-by: J. Bruce Fields <[email protected]> Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
146a8595c6
commit
27ac0ffeac
10 changed files with 69 additions and 17 deletions
|
|
@ -882,7 +882,7 @@ int ecryptfs_truncate(struct dentry *dentry, loff_t new_length)
|
|||
struct dentry *lower_dentry = ecryptfs_dentry_to_lower(dentry);
|
||||
|
||||
mutex_lock(&lower_dentry->d_inode->i_mutex);
|
||||
rc = notify_change(lower_dentry, &lower_ia);
|
||||
rc = notify_change(lower_dentry, &lower_ia, NULL);
|
||||
mutex_unlock(&lower_dentry->d_inode->i_mutex);
|
||||
}
|
||||
return rc;
|
||||
|
|
@ -983,7 +983,7 @@ static int ecryptfs_setattr(struct dentry *dentry, struct iattr *ia)
|
|||
lower_ia.ia_valid &= ~ATTR_MODE;
|
||||
|
||||
mutex_lock(&lower_dentry->d_inode->i_mutex);
|
||||
rc = notify_change(lower_dentry, &lower_ia);
|
||||
rc = notify_change(lower_dentry, &lower_ia, NULL);
|
||||
mutex_unlock(&lower_dentry->d_inode->i_mutex);
|
||||
out:
|
||||
fsstack_copy_attr_all(inode, lower_inode);
|
||||
|
|
|
|||
Loading…
Reference in a new issue