This is the mail archive of the ecos-discuss@sources.redhat.com 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]

AW: Blocking restricted in DSRs


...
> Threads can call blocking functions with the scheduler locked. The
> lock is essentially a per-thread variable so when the thread is
> resumed the lock is returned to its former value.

IOW cyg_scheduler_lock() ensures that the scheduler doesn't run as long as the thread which called cyg_scheduler_lock() doesn't call a synchronization function which calls itself the scheduler, right ?

But still I don't understand the code.
cyg_scheduler_lock() calls Cyg_Scheduler::lock() in sched.inl, which calls inc_sched_lock(). This I find in smp.hxx. I don't see any thread specific data there, so how can this act thread-specific ?

Thanks
Alex

--
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]