commit | 35c84ee5287715c617093b725bc1d3cef9bf1847 | [log] [tgz] |
---|---|---|
author | Paolo Bonzini <pbonzini@redhat.com> | Tue Dec 22 05:20:43 2020 -0500 |
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | Tue Jan 12 20:09:14 2021 +0100 |
tree | 702fd82ca0ddc36c8e5b052685342ad1705c90af | |
parent | bded64d05cb147a8a785ad06413bbf767bba3d65 [diff] |
KVM: x86: fix shift out of bounds reported by UBSAN commit 2f80d502d627f30257ba7e3655e71c373b7d1a5a upstream. Since we know that e >= s, we can reassociate the left shift, changing the shifted number from 1 to 2 in exchange for decreasing the right hand side by 1. Reported-by: syzbot+e87846c48bf72bc85311@syzkaller.appspotmail.com Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>