x86: improve exception debugging

We now dump more information for less common cases,
and this is now centralized code for 32-bit/64-bit.
All of this code is now correctly wrapped around
CONFIG_EXCEPTION_DEBUG. Some cruft and unused defines
removed.

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2019-11-18 12:07:58 -08:00 committed by Andrew Boie
commit 2b67ca8ac9
6 changed files with 125 additions and 68 deletions

View file

@ -17,9 +17,7 @@ void z_x86_exception(z_arch_esf_t *esf)
z_x86_page_fault_handler(esf);
break;
default:
LOG_ERR("** CPU Exception %ld (code %ld/0x%lx) **",
esf->vector, esf->code, esf->code);
z_x86_fatal_error(K_ERR_CPU_EXCEPTION, esf);
z_x86_unhandled_cpu_exception(esf->vector, esf);
CODE_UNREACHABLE;
}
}