[ECOS] interrupt and scheduling (serial driver)

Roland Caßebohm roland.cassebohm@visionsystems.de
Thu Mar 4 09:15:00 GMT 2004

On Mittwoch, 3. März 2004 20:49, Jonathan Larmour wrote:
> Nick Garnett wrote:
> > Martini Stefano <martini@sci.univr.it> writes:
> >>Is the RealTimeclock::dsr called immediately after
> >>the RealTimeclock::isr or is it scheduled by the
> >>scheduler?
> >
> > If the interrupt occurs while the current thread has the scheduler
> > locked then the DSR is deferred (hence the name) until the thread
> > unlocks the scheduler. If the scheduler is not locked, then the DSR
> > will be run immediately as part of the exit from the interrupt.
> Although if there are multiple DSRs to be run, you don't know what order
> they will be run in. This could matter if some DSRs take a long time to
> run, like the serial driver one (unfortuately).

I think the main issue which could keep other DSRs from running to long
is, that the scheduler is locked the whole time data is copied, when
beeing in read or write. If I work with larger buffers this could cause
large delay.

In http://sources.redhat.com/ml/ecos-discuss/2003-02/msg00209.html
I have send a patch. I now the patch is not useable, because there
are some things in which are for functionality which only I needed.
It should only show what I have made.

If you are interested I would make a usable patch. The patch just
make a copy of the relevant pointers with scheluler locked at the
beginning of read or write, writes them back at the end.


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

More information about the Ecos-discuss mailing list