aboutsummaryrefslogtreecommitdiff
path: root/io_uring/advise.h
diff options
context:
space:
mode:
authorGravatar Gustavo A. R. Silva <gustavoars@kernel.org> 2024-03-25 19:34:01 -0600
committerGravatar Christian Brauner <brauner@kernel.org> 2024-04-05 15:53:47 +0200
commit68d6f4f3fbd9b1baae53e7cf33fb3362b5a21494 (patch)
treec04a435f7313dc10206cab7d7a65f94528828ff1 /io_uring/advise.h
parentMerge patch series 'fs: aio: more folio conversion' of https://lore.kernel.or... (diff)
downloadlinux-68d6f4f3fbd9b1baae53e7cf33fb3362b5a21494.tar.gz
linux-68d6f4f3fbd9b1baae53e7cf33fb3362b5a21494.tar.bz2
linux-68d6f4f3fbd9b1baae53e7cf33fb3362b5a21494.zip
fs: Annotate struct file_handle with __counted_by() and use struct_size()
Prepare for the coming implementation by GCC and Clang of the __counted_by attribute. Flexible array members annotated with __counted_by can have their accesses bounds-checked at run-time via CONFIG_UBSAN_BOUNDS (for array indexing) and CONFIG_FORTIFY_SOURCE (for strcpy/memcpy-family functions). While there, use struct_size() helper, instead of the open-coded version. [brauner@kernel.org: contains a fix by Edward for an OOB access] Reported-by: syzbot+4139435cb1b34cf759c2@syzkaller.appspotmail.com Signed-off-by: Edward Adam Davis <eadavis@qq.com> Link: https://lore.kernel.org/r/tencent_A7845DD769577306D813742365E976E3A205@qq.com Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org> Link: https://lore.kernel.org/r/ZgImCXTdGDTeBvSS@neat Reviewed-by: Jan Kara <jack@suse.cz> Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'io_uring/advise.h')
0 files changed, 0 insertions, 0 deletions