public inbox for ecos-discuss@sourceware.org
 help / color / mirror / Atom feed
* [ECOS] about interrupts nesting and vector number decoding
@ 2000-10-24 20:38 yyl
  2000-10-24 21:02 ` Jonathan Larmour
  2000-10-24 23:52 ` Jesper Skov
  0 siblings, 2 replies; 3+ messages in thread
From: yyl @ 2000-10-24 20:38 UTC (permalink / raw)
  To: eCos_discuss

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1242 bytes --]

Hi,i have tow questions need your 
help.
Q1:From document,i know that isr is 
excuted with interrupt disabled,but dsr enable interrupt,so i think the 
interrupt nesting is occured  in dsr.But from another place in the 
document,something is said as followed:
  
      The 
VSR should follow the following approximate plan:
          
........ 
          (Optional) 
Re-enable interrupts to permit nesting. 
          Decode the actual 
external interrupt being delivered from the interrupt controller. This will 
yield the ISR vector number. 
          Using the ISR 
vector number as an index, retrieve the ISR pointer and its data pointer from 
the ISR vector table.  
          Construct a C call 
stack frame. 
 
If re-enable interrupts before isr being called ,it seems that in isr 
interrupt is enabled.
Who can tell me the procedure  about the interrupt nesting?
Q2:i think the macro of  hal_intc_decode in the file variant.inc only 
decodes the vector from SIU level,i don't find the code decoding
the vector using the rigester CIVR of CPM?
     Thanks!

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ECOS] about interrupts nesting and vector number decoding
  2000-10-24 20:38 [ECOS] about interrupts nesting and vector number decoding yyl
@ 2000-10-24 21:02 ` Jonathan Larmour
  2000-10-24 23:52 ` Jesper Skov
  1 sibling, 0 replies; 3+ messages in thread
From: Jonathan Larmour @ 2000-10-24 21:02 UTC (permalink / raw)
  To: yyl; +Cc: eCos_discuss

> yyl wrote:
> Q1:From document,i know that isr is excuted with interrupt disabled,but
> dsr enable interrupt,so i think the interrupt nesting is occured  in
> dsr.But from another place in the document,

which document?

>something is said as followed:
> 
>       The VSR should follow the following approximate plan:
>           ........
>           (Optional) Re-enable interrupts to permit nesting.
>           Decode the actual external interrupt being delivered from the
> interrupt controller. This will yield the ISR vector number.
>           Using the ISR vector number as an index, retrieve the ISR
> pointer and its data pointer from the ISR vector table.
>           Construct a C call stack frame.
> 
> If re-enable interrupts before isr being called ,it seems that in isr
> interrupt is enabled.
> Who can tell me the procedure  about the interrupt nesting?

I don't know where this comes from to derive the context. It certainly
isn't
http://sources.redhat.com/ecos/docs-latest/porting/hal-interrupts.html for
example. I don't know whether this is talking about writing your own VSRs
or the default interrupt VSR for porting.

But anyway, as you can see permitting nesting is optional. And in fact I
don't know any eCos targets where nested ISRs are permitted by default, but
I may be wrong of course. And when it does say you _could_ allow nesting,
this would primarily be aimed at allowing higher priority interrupts to
interrupt lower priority ones. Until processed, any interrupt being handled
would remain masked until processing was completed, usually in the DSR.

Jifl
-- 
Red Hat, 35 Cambridge Place, Cambridge, UK. CB2 1NS  Tel: +44 (1223) 728762
"Plan to be spontaneous tomorrow."  ||  These opinions are all my own fault

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [ECOS] about interrupts nesting and vector number decoding
  2000-10-24 20:38 [ECOS] about interrupts nesting and vector number decoding yyl
  2000-10-24 21:02 ` Jonathan Larmour
@ 2000-10-24 23:52 ` Jesper Skov
  1 sibling, 0 replies; 3+ messages in thread
From: Jesper Skov @ 2000-10-24 23:52 UTC (permalink / raw)
  To: yyl; +Cc: eCos_discuss

>>>>> "yyl" == yyl  <ylyuan@davform.com> writes:

yyl> Q2:i think the macro of hal_intc_decode
yyl> in the file variant.inc only = decodes the vector from SIU
yyl> level,i don't find the code decoding the vector using the
yyl> rigester CIVR of CPM?  Thanks!

Correct, only 1st level decoding is done in the assembly code. Further
decoding is done by an arbiter. See the var_intr.c file. 

There's been some discussion on the CPM interrupt handling the last
couple of weeks on the list - you may want to go back and read all
those.

Jesper

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2000-10-24 23:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2000-10-24 20:38 [ECOS] about interrupts nesting and vector number decoding yyl
2000-10-24 21:02 ` Jonathan Larmour
2000-10-24 23:52 ` Jesper Skov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).