]> git.itanic.dy.fi Git - linux-stable/commit
arm/arm64: KVM: Fix set_clear_sgi_pend_reg offset
authorChristoffer Dall <christoffer.dall@linaro.org>
Thu, 25 Sep 2014 16:41:07 +0000 (18:41 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 4 Jul 2015 02:49:06 +0000 (19:49 -0700)
commit009ac1f72ca7cc631fae7b07333c3c8e5d7bccf6
tree689b8947e5d3f7f2fda86e055efc22a429f55177
parent79f03a7665abcb4121a091a0f2008ea83c4bb0d1
arm/arm64: KVM: Fix set_clear_sgi_pend_reg offset

commit 0fea6d7628ed6e25a9ee1b67edf7c859718d39e8 upstream.

The sgi values calculated in read_set_clear_sgi_pend_reg() and
write_set_clear_sgi_pend_reg() were horribly incorrectly multiplied by 4
with catastrophic results in that subfunctions ended up overwriting
memory not allocated for the expected purpose.

This showed up as bugs in kfree() and the kernel complaining a lot of
you turn on memory debugging.

This addresses: http://marc.info/?l=kvm&m=141164910007868&w=2

Reported-by: Shannon Zhao <zhaoshenglong@huawei.com>
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
Signed-off-by: Shannon Zhao <shannon.zhao@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
virt/kvm/arm/vgic.c