Re: How to know if scheduler has started?

Grant Edwards <[email protected]>
Newsgroups gmane.os.ecos.general
Message-ID <[email protected]>
On 2013-11-01, Nick Garnett <[email protected]> wrote:
>
>> OTOH, are you are allowed to lock/unlock mutexes from initialization
>> code?  Maybe I'm misremembering, but I thought that was forbidden?
>
> You are allowed to lock/unlock a mutex during initialization. That is
> why the idle thread is set current throughout the init code, and why the
> trick you mention above will work.

Except the trick I mentioned above does _not_ work when called from
device driver intialization code.  I haven't tracked down which of the
two calls fails in that case, but one of them causes a segfault when
called from driver init code (but works fine when called from
cyg_user_start()).

-- 
Grant


-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.