This is the mail archive of the
ecos-devel@sourceware.org
mailing list for the eCos project.
Re: Interrupt controller question
On Wed, 2006-07-12 at 11:01 +0200, Lars Poeschel wrote:
> Am Dienstag, 11. Juli 2006 15:10 schrieb Gary Thomas:
> > Lars Poeschel wrote:
> > > Hello!
> > >
> > > I am porting ecos to FR30 / FR50 archtitecture from Fujitsu.
> > > I have a question to the interrupt controller management macros.
> > > The FR30 architecture has 48 different interrupt sources. Every interrupt
> > > a level can be assigned. 15 different levels are possible.
> > > What can I do to have that fit best into ecos, which seems to expect to
> > > be able to mask every single interrupt by its vector number ?
> > > By the way, the interrupt levels of the fr30 define some sort of priority
> > > management. A higher priotized interrupt can interrupt a lower priorized
> > > one.
> >
> > Have you looked at how it was done on the other Fujitsu platforms
> > (hal/frv)?
>
> It was a good idea pointing me this direction, but did not help me. :-(
> FRV and FR30 architecture unfortunately do not have much in common. Hardware
> manual for frv is not directly available from fujitsu, but when I look at the
> frv code, it seems that frv only has 15 interrupt sources which are masked
> directly. This directly corresponds to the ecos macros.
No, the FRV may have many more than 15 sources. It does have 15 priority
levels. Each individual source may be assigned to any one of the levels.
Masking is performed on the levels. That is, you can mask all interrupts
at level 12, or level 3, etc. The individual sources may or may not be
maskable at their hardware source, but that is something a driver would
do. It is not usually supported through the HAL macros unless there is
another interrupt controller feeding into one of the external interrupt
inputs.
See hal/frv/mb93091/current/src/mb93091_misc.c:hal_interrupt_configure()
That's where the source -> level mapping is setup in the IRR registers.
The actual mappings are defined statically in
hal/frv/mb93091/current/include/plf_ints.h
--Mark