summaryrefslogtreecommitdiff
path: root/fs/reiserfs/acl.h
diff options
context:
space:
mode:
authorEric Biggers <ebiggers@google.com>2022-12-23 23:36:28 +0300
committerEric Biggers <ebiggers@google.com>2023-01-10 06:05:47 +0300
commit284d5db5f99efa9e3549eb3cba39379d48879db1 (patch)
tree992acc4d74a9accc0bdbb1f73b0b4ac2d311346e /fs/reiserfs/acl.h
parent86f66569baca98478b7ff2f49c8ee54cf3b108cd (diff)
downloadlinux-284d5db5f99efa9e3549eb3cba39379d48879db1.tar.xz
fsverity: use unsigned long for level_start
fs/verity/ isn't consistent with whether Merkle tree block indices are 'unsigned long' or 'u64'. There's no real point to using u64 for them, though, since (a) a Merkle tree with over ULONG_MAX blocks would only be needed for a file larger than MAX_LFS_FILESIZE, and (b) for reads, the status of all Merkle tree blocks has to be tracked in memory. Therefore, let's make things a bit more efficient on 32-bit systems by using 'unsigned long[]' for merkle_tree_params::level_start, instead of 'u64[]'. Also, to be extra safe, explicitly check that there aren't more than ULONG_MAX Merkle tree blocks. Signed-off-by: Eric Biggers <ebiggers@google.com> Reviewed-by: Andrey Albershteyn <aalbersh@redhat.com> Tested-by: Ojaswin Mujoo <ojaswin@linux.ibm.com> Link: https://lore.kernel.org/r/20221223203638.41293-2-ebiggers@kernel.org
Diffstat (limited to 'fs/reiserfs/acl.h')
0 files changed, 0 insertions, 0 deletions