kvmppc: Fix BUILD_BUG_ON condition
Subsystems (2)
PATCH 1/1 kvmppc: Fix BUILD_BUG_ON condition
The old BUILD_BUG_ON implementation didn't work with __builtin_constant_p(). Fixing that revealed this test had been inverted for a long time without anybody noticing...
Signed-off-by Hollis Blanchard <[email protected]>
arch/powerpc/kvm/timing.h +1 -1
@@ -48,7 +48,7 @@ static inline void kvmppc_set_exit_type(static inline void kvmppc_account_exit_stat (struct kvm_vcpu *vcpu,int type) {/* type has to be known at build time for optimization */ -BUILD_BUG_ON (__builtin_constant_p (type)); +BUILD_BUG_ON (!__builtin_constant_p (type));switch (type) {case EXT_INTR_EXITS : vcpu->stat.ext_intr_exits++;
Avi Kivity
AppliedQuoted 4 lines · Hollis Blanchard
The old
BUILD_BUG_ONimplementation didn't work with__builtin_constant_p(). Fixing that revealed this test had been inverted for a long time without anybody noticing...
Applied, thanks.
Signature · 1 line
error compiling committee.c: too many arguments to function