Commit a8b373ee authored by Trond Myklebust's avatar Trond Myklebust
Browse files

NFS: Limit the size of the access cache by default



Currently, we have no real limit on the access cache size (we set it
to ULONG_MAX). That can lead to credentials getting pinned for a
very long time on lots of files if you have a system with a lot of
memory.

Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
parent 49cd3254
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2309,7 +2309,7 @@ static DEFINE_SPINLOCK(nfs_access_lru_lock);
static LIST_HEAD(nfs_access_lru_list);
static atomic_long_t nfs_access_nr_entries;

static unsigned long nfs_access_max_cachesize = ULONG_MAX;
static unsigned long nfs_access_max_cachesize = 4*1024*1024;
module_param(nfs_access_max_cachesize, ulong, 0644);
MODULE_PARM_DESC(nfs_access_max_cachesize, "NFS access maximum total cache length");