SCHED_ENQUEUE: tighten checks on locking
authorbernie <bernie@38d2e660-2303-0410-9eaa-f027e97ec537>
Wed, 3 Sep 2008 08:17:51 +0000 (08:17 +0000)
committerbernie <bernie@38d2e660-2303-0410-9eaa-f027e97ec537>
Wed, 3 Sep 2008 08:17:51 +0000 (08:17 +0000)
commitb0ba66e728f0885d53e7836898ea60902c818aa8
tree01c1b2bde9c37c5e825c7de4c8fa82df741fd96f
parent9002e60f9cc2f2112180d706abe7dfc4f14ebf0f
SCHED_ENQUEUE: tighten checks on locking

Factor out the two different implementations and ensure
modifications happen with inteerrupts disabled.  This uncovered
a latent bug in our semaphore sleep code.

Also explicitly document our locking requirements for ProcReadyList.
The comment previously claimed that proc_forbid() would offer enough
protection, which is, of course, bullshit.

git-svn-id: https://src.develer.com/svnoss/bertos/trunk@1773 38d2e660-2303-0410-9eaa-f027e97ec537
bertos/kern/proc_p.h
bertos/kern/sem.c