Messages in this thread |  | | | Subject | Re: [PATCH] x86_64 early_idt_handler improvements | | From | Andi Kleen <> | | Date | Fri, 11 Jan 2008 07:27:07 +0100 | |
Roland McGrath <roland@redhat.com> writes:
> It's not too pretty, but I found this made the "PANIC: early exception"
> messages become much more reliably useful: 1. print the vector number,
> 2. print the %cs value, 3. handle error-code-pushing vs non-pushing vectors.
For what do you need cs? It should be always the same for early boot.
>
> Signed-off-by: Roland McGrath <roland@redhat.com>
> ---
> arch/x86/kernel/head64.c | 6 ++++--
> arch/x86/kernel/head_64.S | 34 ++++++++++++++++++++++++++++++----
> 2 files changed, 34 insertions(+), 6 deletions(-)
>
> diff --git a/arch/x86/kernel/head64.c b/arch/x86/kernel/head64.c
> index 4a1c135..0000000 100644
> --- a/arch/x86/kernel/head64.c
> +++ b/arch/x86/kernel/head64.c
> @@ -48,6 +48,8 @@ static void __init copy_bootdata(char *r
> }
> }
>
> +extern const char early_idt_handlers[IDT_ENTRIES][10];
I don't think that minor improvement is worth that much memory
(several KB for the array and some more for all the handlers)
Also in my experience it is not that difficult to work out from
which vector the exception came from. There are not that many variants
anyways; it's near always #GP or #PF.
-Andi
|  |