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]

fatal error:set_priority()


Dear nickg,
about changing a thread's priority in ecos,I have some different opinion:
ecos method:
remove "this" thread from queue which the thread exists in ,then set new
priority and add the thread into new ready queue or old quque.if need reschedule,
set need_sched and unlock()

questions:
1 if this thread 's state==RUNNING( current thread or not current thread) and owned a mutex,and ecos set a lower priority,then,all thread waiting mutex were waiting long term undetermined!
2 if this thread 's state!=RUNNING but sleeping for a mutex, and ecos set a highest priority in its queue,why not priority inherent occurs?
3not only mutex,but other critical resource:files,device,the same problem exists!
suggestion:
this topic is complex,
i think the function:set_priority() should be called with more limitations:
it should be called only for suspended thread,reset thread.




_________________________________________________________________
享用世界上最大的电子邮件系统— MSN Hotmail。http://www.hotmail.com/cn


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


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