From fd9972ecc54b7827473c4de5f406c0a73d8658ef Mon Sep 17 00:00:00 2001 From: Wei Liu Date: Mon, 25 Jan 2021 15:18:21 +0000 Subject: [PATCH] hypervisor: fix exception vector numbers According to Intel SDM, #DE should be 0 and #DB should be 1. Signed-off-by: Wei Liu --- hypervisor/src/arch/x86/mod.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hypervisor/src/arch/x86/mod.rs b/hypervisor/src/arch/x86/mod.rs index c9489f2c6..bfa21a83b 100644 --- a/hypervisor/src/arch/x86/mod.rs +++ b/hypervisor/src/arch/x86/mod.rs @@ -43,8 +43,8 @@ pub const NUM_IOAPIC_PINS: usize = 24; #[allow(dead_code)] #[derive(Clone, Debug)] pub enum Exception { - DE = 1, // Divide Error - DB = 2, // Debug Exception + DE = 0, // Divide Error + DB = 1, // Debug Exception BP = 3, // Breakpoint OF = 4, // Overflow BR = 5, // BOUND Range Exceeded