Whamcloud - gitweb
LU-16118 build: Workaround __write_overflow_field errors 64/53264/2
authorShaun Tancheff <shaun.tancheff@hpe.com>
Tue, 28 Nov 2023 07:02:25 +0000 (23:02 -0800)
committerOleg Drokin <green@whamcloud.com>
Tue, 27 Feb 2024 05:40:40 +0000 (05:40 +0000)
commit62307620f0bbce8ceb6c28f473f37ffcd114f9c2
treed15f281f06b227528d9731bed36efa76219798bd
parenteefca0a2a1e4e840ced50c0a458d2c697c5c606a
LU-16118 build: Workaround __write_overflow_field errors

Linux commit v5.17-rc3-1-gf68f2ff91512
   fortify: Detect struct member overflows in memcpy() at compile-time

memcpy and memset of collections of struct members
will trigger:

error: call to '__write_overflow_field' declared with attribute
   warning: detected write beyond size of field (1st parameter);
   maybe use struct_group()?
   [-Werror] __write_overflow_field(p_size_field, size);

Lustre-change: https://review.whamcloud.com/48364
Lustre-commit: a3a51806ef361f55421a1bc07f64c78730ae50d5

Test-Parameters: trivial
HPE-bug-id: LUS-11194
Signed-off-by: Shaun Tancheff <shaun.tancheff@hpe.com>
Change-Id: Iacd1ab03d1b90ce62b5d7b65e1cd518a5f7981f2
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/53264
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
libcfs/include/libcfs/linux/linux-misc.h
lustre/include/cl_object.h
lustre/obdclass/md_attrs.c