Re: [PATCH] KVM: x86/mmu: Fix a benign Bitwise vs. Logical OR mixup
From: Paolo Bonzini
Date: Wed Jan 15 2020 - 13:20:30 EST
On 09/01/20 17:36, Sean Christopherson wrote:
>>> You also don't want to convert the expression result to zero.
>> The function is static inline bool, so it's almost certainly a mistake
>> originally. The != 0 is superfluous, but this will get inlined anyway.
> Ya, the bitwise-OR was added in commit 25d92081ae2f ("nEPT: Add nEPT
> violation/misconfigration support"), and AFAICT it's unintentional.
It may not be intentional in this case, but it's certainly the kind of
code that I would have fun writing. :)
Paolo