This is the mail archive of the ecos-discuss@sourceware.org mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: eCos Startup, where to enable interruots the first time


On Sat, 26 Mar 2011, Richard Rauch wrote:

> Hi,
> 
> I'm in doubt, when while startup of eCos the interrupts should be enabled
> initially.
> I have read somewhere in cyg_start or cyg_scheduler_start, but I cannot
> finde where exactely.

Hi,

It seems it was here
http://ecos.sourceware.org/docs-latest/ref/kernel-overview.html [Calling
Contexts]

> Of course, I can do it somewhere, but I want to follow the eCos standard.
 
Usually interrupt handlers are created, attached and configured during
system initialization, while global interrupts are still disabled. On
most hardware it will also be necessary to call cyg_interrupt_unmask,
since the sensible default for interrupt masking is to ignore any
interrupts for which no handler is installed.

Look around
% grep cyg_drv_interrupt_unmask $ECOS_REPOSITORY/devs

So, in the most cases you do not need to enable interrupts "by hands" if
you use eCos kernel, otherwise, take a look on these eCos tests (== eCos
standards)

  hal/common/current/tests/intr.c
  kernel/current/tests/kintr0.c
  kernel/current/tests/intr0.cxx


Sergei

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]