diff options
author | Philipp Reisner <philipp.reisner@linbit.com> | 2024-11-15 23:46:02 +0300 |
---|---|---|
committer | Kees Cook <kees@kernel.org> | 2024-11-17 08:15:41 +0300 |
commit | d7a516c6eeae29144649f1c3f586fa580ec9e040 (patch) | |
tree | 517312ec6449d6394bc824ca860358073913d18a /rust/helpers/helpers.c | |
parent | a508ef4b1dcc82227edc594ffae583874dd425d7 (diff) | |
download | linux-d7a516c6eeae29144649f1c3f586fa580ec9e040.tar.xz |
compiler.h: Fix undefined BUILD_BUG_ON_ZERO()
<linux/compiler.h> defines __must_be_array() and __must_be_cstr() and
both expand to BUILD_BUG_ON_ZERO(), but <linux/build_bug.h> defines
BUILD_BUG_ON_ZERO(). Including <linux/build_bug.h> in
<linux/compiler.h> would create a cyclic dependency as
<linux/build_bug.h> already includes <linux/compiler.h>.
Fix that by defining __BUILD_BUG_ON_ZERO_MSG() in <linux/compiler.h>
and using that for __must_be_array() and __must_be_cstr().
Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Link: https://lore.kernel.org/r/20241115204602.249590-1-philipp.reisner@linbit.com
Signed-off-by: Kees Cook <kees@kernel.org>
Diffstat (limited to 'rust/helpers/helpers.c')
0 files changed, 0 insertions, 0 deletions