diff options
author | Trond Myklebust <trond.myklebust@hammerspace.com> | 2021-11-07 15:15:44 +0100 |
---|---|---|
committer | Trond Myklebust <trond.myklebust@hammerspace.com> | 2021-11-07 15:23:14 +0100 |
commit | f96f8cc4a63dd645e07ea9712be4e0a76ea4ec1f (patch) | |
tree | 85ebbff5baf8324fc653747813e5b5d4a9c12e51 /fs/nfs/nfs4session.h | |
parent | NFS: Remove the nfs4_label argument from decode_getattr_*() functions (diff) | |
download | linux-f96f8cc4a63dd645e07ea9712be4e0a76ea4ec1f.tar.xz linux-f96f8cc4a63dd645e07ea9712be4e0a76ea4ec1f.zip |
NFSv4: Sanity check the parameters in nfs41_update_target_slotid()
Ensure that the values supplied by the server do not exceed the size of
the largest allowed slot table.
Reported-by: <rtm@csail.mit.edu>
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
Diffstat (limited to 'fs/nfs/nfs4session.h')
-rw-r--r-- | fs/nfs/nfs4session.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/nfs/nfs4session.h b/fs/nfs/nfs4session.h index 3de425f59b3a..351616c61df5 100644 --- a/fs/nfs/nfs4session.h +++ b/fs/nfs/nfs4session.h @@ -12,6 +12,7 @@ #define NFS4_DEF_SLOT_TABLE_SIZE (64U) #define NFS4_DEF_CB_SLOT_TABLE_SIZE (16U) #define NFS4_MAX_SLOT_TABLE (1024U) +#define NFS4_MAX_SLOTID (NFS4_MAX_SLOT_TABLE - 1U) #define NFS4_NO_SLOT ((u32)-1) #if IS_ENABLED(CONFIG_NFS_V4) |