cvs commit: src/sys/sys kse.h src/sys/kern kern_thread.c
David Xu
davidxu at FreeBSD.org
Mon Apr 21 00:28:01 PDT 2003
davidxu 2003/04/21 00:28:00 PDT
FreeBSD src repository
Modified files:
sys/sys kse.h
sys/kern kern_thread.c
Log:
Introduce two flags to control upcall behaviour:
o KMF_NOUPCALL
Ask kse_release to not return to userland upcall entry, but instead
direct returns to userland by using current thread's stack and return
address on stack. This flags is intended to be used by UTS in critical
region to wait another UTS thread to leave critical region, by using
kse_release with this flag to avoid spinnng and burning CPU. Also this
flags can be used by UTS to poll completed context when there is nothing
to do in userland and needn't restart from its entry like normal upcall.
o KMF_NOCOMPLETED
Ask kernel to not bring completed thread contexts back to userland when
doing upcall, this flags is intend to be used with above flag when an
upcall thread is in critical region and can not process completed contexts
at that time.
Tested by: deischen
Revision Changes Path
1.120 +36 -51 src/sys/kern/kern_thread.c
1.13 +4 -0 src/sys/sys/kse.h
More information about the cvs-src
mailing list