I haven't done a whole lot of testing of these, just enough to see that it normally works _and_ that it would catch the bug Matt reported. I don't have time or resources to find and fix the bugs this would reveal, hence just an RFC for people to consider.
Rasmus Villemoes (2): build_bug.h: add wrapper for _Static_assert global-data.h: add build-time sanity check of sizeof(struct global_data) include/asm-generic/global_data.h | 5 +++++ include/linux/build_bug.h | 19 +++++++++++++++++++ 2 files changed, 24 insertions(+) -- 2.29.2