linux-mips
[Top] [All Lists]

Re: Got trap No.23 when booting mips32 ?

To: "wilbur.chan" <wilbur512@gmail.com>
Subject: Re: Got trap No.23 when booting mips32 ?
From: David Daney <ddaney@caviumnetworks.com>
Date: Thu, 22 Oct 2009 09:03:05 -0700
Cc: "Kevin D. Kissell" <kevink@paralogos.com>, Sergei Shtylyov <sshtylyov@ru.mvista.com>, linux-mips@linux-mips.org
In-reply-to: <e997b7420910220755m3e78c397ia5f183c580fb170b@mail.gmail.com>
Original-recipient: rfc822;linux-mips@linux-mips.org
References: <e997b7420910210740l4a8fefai27c81152a6c288ef@mail.gmail.com> <4ADF32D1.6030801@ru.mvista.com> <e997b7420910211704w67517b3bud6f4757a35945ba@mail.gmail.com> <4ADFAC5E.5020506@paralogos.com> <e997b7420910220755m3e78c397ia5f183c580fb170b@mail.gmail.com>
Sender: linux-mips-bounce@linux-mips.org
User-agent: Thunderbird 2.0.0.21 (X11/20090320)
wilbur.chan wrote:
2009/10/22 Kevin D. Kissell <kevink@paralogos.com>:
wilbur.chan wrote:
Kernal didn't resgister IRQ 23 when booting. Hmm....the only '23'
number I can find in kernel is in traps.c.

Why a 23 IRQ was triggered?


The usual reason would be a failure to correctly initialize an interrupt
controller, or the Status.IM mask field.  The kernel complains precisely
*because* IRQ 23 wasn't registered, but an interrupt was nevertheless
delivered that was decoded as being that IRQ.

        Regards,

        Kevin K.



Thanks for your suggestion.

And I found that , as a matter of  fact , kernel has registered No.23 as a trap.

In trap_init :

/*
1419          * Only some CPUs have the watch exceptions.
1420          */
1421         if (cpu_has_watch)
1422                 set_except_vector(23, handle_watch);


So, if a No.23 "signal" happened , kernel should  invoke handle_watch instead.


But why here kernel complained ? and why kernel entered the IRQ branch
(do_IRQ) rather than trap branch?


You still don't understand. You are not getting the watch exception. The '23' you see is not at all related to the exception code in the C0_cause register.

David Daney

<Prev in Thread] Current Thread [Next in Thread>