]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
selftests: kvm: Fix the segment descriptor layout to match the actual layout
authorAaron Lewis <aaronlewis@google.com>
Mon, 12 Oct 2020 19:47:13 +0000 (12:47 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 24 Nov 2020 12:29:00 +0000 (13:29 +0100)
commit58ced37417899a98947f8ca24798443a0a9db099
treef3f735fc0efd6db4cf54f3c957ba9fcb3f933e1e
parent8ebc41496f6e892627d40fe8273766e131bee8c9
selftests: kvm: Fix the segment descriptor layout to match the actual layout

[ Upstream commit df11f7dd5834146defa448acba097e8d7703cc42 ]

Fix the layout of 'struct desc64' to match the layout described in the
SDM Vol 3, Chapter 3 "Protected-Mode Memory Management", section 3.4.5
"Segment Descriptors", Figure 3-8 "Segment Descriptor".  The test added
later in this series relies on this and crashes if this layout is not
correct.

Signed-off-by: Aaron Lewis <aaronlewis@google.com>
Reviewed-by: Alexander Graf <graf@amazon.com>
Message-Id: <20201012194716.3950330-2-aaronlewis@google.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
tools/testing/selftests/kvm/include/x86_64/processor.h
tools/testing/selftests/kvm/lib/x86_64/processor.c