gcc-7.5 build fails: intel_guc_submission.c FIELD_PREP: mask is not constant
According to https://www.kernel.org/doc/html/next/process/changes.html the kernel should build with minimum gcc 5.1
But building latest Linus master with gcc-7.5 fails:
In file included from <command-line>:0:0:
In function '__guc_context_policy_add_preemption_timeout.isra.102',
inlined from '__guc_context_set_preemption_timeout' at drivers/gpu/drm/i915/gt/uc/intel_guc_submission.c:3182:3:
././include/linux/compiler_types.h:449:38: error: call to '__compiletime_assert_818' declared with attribute error: FIELD_PREP: mask is not constant
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^
././include/linux/compiler_types.h:430:4: note: in definition of macro '__compiletime_assert'
prefix ## suffix(); \
...
It looks like this was previously reported by Borislav Petkov at https://lore.kernel.org/lkml/Y3ehHsiwzJIcE9+%2F@zn.tnic/T/