Skip to content

Commit b788dc5

Browse files
jamesasimmonsgregkh
authored andcommitted
staging: lustre: llite: drop acl from cache
Commit b8a7a3a change get_acl() for posix xattr to always cache the ACL which increases the reference count. That reference count can be reduced by have ll_get_acl() call forget_cached_acl() which it wasn't. When an inode gets deleted by Lustre the POSIX ACL reference count is tested to ensure its 1 and if not produces an error. Since forget_cached_acl() was not called Lustre started to complain. This patch changes ll_get_acl() to call forget_cached_acl(). Signed-off-by: James Simmons <[email protected]> Reviewed-by: Andreas Gruenbacher <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent c6c7a17 commit b788dc5

File tree

1 file changed

+1
-0
lines changed
  • drivers/staging/lustre/lustre/llite

1 file changed

+1
-0
lines changed

drivers/staging/lustre/lustre/llite/file.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3124,6 +3124,7 @@ struct posix_acl *ll_get_acl(struct inode *inode, int type)
31243124
spin_lock(&lli->lli_lock);
31253125
/* VFS' acl_permission_check->check_acl will release the refcount */
31263126
acl = posix_acl_dup(lli->lli_posix_acl);
3127+
forget_cached_acl(inode, type);
31273128
spin_unlock(&lli->lli_lock);
31283129

31293130
return acl;

0 commit comments

Comments
 (0)