summaryrefslogtreecommitdiff
path: root/fs/nfs/delegation.c
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@hammerspace.com>2022-01-29 21:42:01 +0300
committerTrond Myklebust <trond.myklebust@hammerspace.com>2022-02-26 02:50:12 +0300
commit9c00fd9acba81070e9413a468df57cf89d6ee960 (patch)
tree89c74b6286858544657317aa626bbb9a7ea5dfff /fs/nfs/delegation.c
parentd7867712d81c05680beff2c9645ff1e8fa59a41d (diff)
downloadlinux-9c00fd9acba81070e9413a468df57cf89d6ee960.tar.xz
NFSv4: Charge NFSv4 open state trackers to kmemcg
Allow kmemcg to limit the number of NFSv4 delegation, lock and open state trackers. Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'fs/nfs/delegation.c')
-rw-r--r--fs/nfs/delegation.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/nfs/delegation.c b/fs/nfs/delegation.c
index 7c9eb679dbdb..5c97cad741a7 100644
--- a/fs/nfs/delegation.c
+++ b/fs/nfs/delegation.c
@@ -439,7 +439,7 @@ int nfs_inode_set_delegation(struct inode *inode, const struct cred *cred,
struct nfs_delegation *freeme = NULL;
int status = 0;
- delegation = kmalloc(sizeof(*delegation), GFP_NOFS);
+ delegation = kmalloc(sizeof(*delegation), GFP_KERNEL_ACCOUNT);
if (delegation == NULL)
return -ENOMEM;
nfs4_stateid_copy(&delegation->stateid, stateid);