KVM: apic: avoid calculating pending eoi from an uninitialized val
Quoted 9 lines · Vitaly Kuznetsov
Quoted 5 lines · linmiaohe
From: Miaohe Lin <[email protected]>
When
pv_eoi_get_user()fails, 'val' may remain uninitialized and the return value ofpv_eoi_get_pending()becomes random. Fix the issue by initializing the variable.Well, now the 'perfect' commit message doesn't match the patch :-). I think you (or Paolo upon commit) can just drop the last sentence.
My bad, sorry about it, I should be more careful about it. I will drop the last sentence in v3. Thanks.