This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: a confusion regarding role of schedlock
- From: Brij Bihari Pandey <fuzzhead012 at yahoo dot com>
- To: ecos-discuss at sources dot redhat dot com
- Cc: ecos-discuss at sources dot redhat dot com
- Date: Fri, 13 Sep 2002 01:36:18 -0700 (PDT)
- Subject: Re: [ECOS] a confusion regarding role of schedlock
Thanks Rich,
but my confusion is about - we took sched lock as we
didn't want the threadswitch to happen, yet because of
reschedule the threadswitch will happen.
brij
> > cyg_bool Cyg_Counting_Semaphore::wait()
> > {
> > -- ..... --
> > // Prevent preemption
> > Cyg_Scheduler::lock();
> > -- ..... --
> > // Allow other threads to run
> > Cyg_Scheduler::reschedule();
> > -- ..... --
> > // Unlock the scheduler
> > Cyg_Scheduler::unlock();
> > -- ..... --
> > }
__________________________________________________
Do you Yahoo!?
Yahoo! News - Today's headlines
http://news.yahoo.com
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss