Skip to content

Commit c8c3fd1

Browse files
yukaixiongJoelgranados
authored andcommitted
sunrpc: simplify rpcauth_cache_shrink_count()
It is inappropriate to use sysctl_vfs_cache_pressure here. The sysctl is documented as: This percentage value controls the tendency of the kernel to reclaim the memory which is used for caching of directory and inode objects. So, simplify result of rpcauth_cache_shrink_count() to "return number_cred_unused;". Signed-off-by: Kaixiong Yu <[email protected]> Reviewed-by: Kees Cook <[email protected]> Acked-by: Anna Schumaker <[email protected]> Acked-by: Jeff Layton <[email protected]> Reviewed-by: Jeff Layton <[email protected]> Signed-off-by: Joel Granados <[email protected]>
1 parent f5d64ae commit c8c3fd1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/sunrpc/auth.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -489,7 +489,7 @@ static unsigned long
489489
rpcauth_cache_shrink_count(struct shrinker *shrink, struct shrink_control *sc)
490490

491491
{
492-
return number_cred_unused * sysctl_vfs_cache_pressure / 100;
492+
return number_cred_unused;
493493
}
494494

495495
static void

0 commit comments

Comments
 (0)