Commit 36d4e7a0 authored by Paolo Bonzini's avatar Paolo Bonzini Committed by Yongqiang Liu
Browse files

kvm: fix previous commit for 32-bit builds

stable inclusion
from stable-v4.19.195
commit 270dadd7ea31c1bc43a0b1de118a30c2238171a8
category: bugfix
bugzilla: https://gitee.com/src-openeuler/kernel/issues/I9R4K5


CVE: CVE-2021-47277

--------------------------------

commit 4422829e upstream.

array_index_nospec does not work for uint64_t on 32-bit builds.
However, the size of a memory slot must be less than 20 bits wide
on those system, since the memory slot must fit in the user
address space.  So just store it in an unsigned long.

Signed-off-by: default avatarPaolo Bonzini <pbonzini@redhat.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarYongqiang Liu <liuyongqiang13@huawei.com>
parent 81f70a86
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment