Install the ASM_TRY() exception handler for all known exception vectors so that ASM_TRY() can be used for other exceptions, e.g. #PF. ASM_TRY() might not Just Work in all cases, but there's no good reason to limit usage to just #DE, #UD, and #GP. Signed-off-by: Sean Christopherson <seanjc@xxxxxxxxxx> --- lib/x86/desc.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/x86/desc.c b/lib/x86/desc.c index a20be92..b293ae4 100644 --- a/lib/x86/desc.c +++ b/lib/x86/desc.c @@ -301,12 +301,12 @@ void setup_idt(void) idt_initialized = true; for (i = 0; i < 32; i++) { - if (idt_handlers[i]) - set_idt_entry(i, idt_handlers[i], 0); + if (!idt_handlers[i]) + continue; + + set_idt_entry(i, idt_handlers[i], 0); + handle_exception(i, check_exception_table); } - handle_exception(0, check_exception_table); - handle_exception(6, check_exception_table); - handle_exception(13, check_exception_table); } void load_idt(void) -- 2.38.0.rc1.362.ged0d419d3c-goog