Cleanup comments and change CV_WakeAll -> CV_Broacast

This commit is contained in:
Ali Mashtizadeh 2023-10-16 15:07:17 -04:00
parent 7f6b72c963
commit bd44784c5f
2 changed files with 9 additions and 10 deletions

View File

@ -70,12 +70,12 @@ CV_Signal(CV *cv)
} }
/** /**
* CV_WakeAll -- * CV_Broadcast --
* *
* Wake all threads waiting on the condition. * Wake all threads waiting on the condition.
*/ */
void void
CV_WakeAll(CV *cv) CV_Broadcast(CV *cv)
{ {
WaitChannel_WakeAll(&cv->chan); WaitChannel_WakeAll(&cv->chan);

View File

@ -51,7 +51,7 @@ WaitChannel_Destroy(WaitChannel *wchan)
/** /**
* WaitChannel_Lock -- * WaitChannel_Lock --
* *
* Acquires the wait channel lock. * Acquires the wait channel lock.
*/ */
void void
WaitChannel_Lock(WaitChannel *wchan) WaitChannel_Lock(WaitChannel *wchan)
@ -62,11 +62,10 @@ WaitChannel_Lock(WaitChannel *wchan)
/** /**
* WaitChannel_Sleep -- * WaitChannel_Sleep --
* *
* Places the current thread to asleep while releasing the wait channel * Places the current thread to asleep while releasing the wait channel lock.
* lock.
* *
* Side Effect: * Side Effect:
* Retains a reference to thread until the thread is woken up. * Retains a reference to thread until the thread is woken up.
*/ */
void void
WaitChannel_Sleep(WaitChannel *wchan) WaitChannel_Sleep(WaitChannel *wchan)
@ -83,10 +82,10 @@ WaitChannel_Sleep(WaitChannel *wchan)
/** /**
* WaitChannel_Wake -- * WaitChannel_Wake --
* *
* Wake up a single thread. * Wake up a single thread.
* *
* Side Effects: * Side Effects:
* Releases the thread reference once complete. * Releases the thread reference once complete.
*/ */
void void
WaitChannel_Wake(WaitChannel *wchan) WaitChannel_Wake(WaitChannel *wchan)
@ -108,10 +107,10 @@ WaitChannel_Wake(WaitChannel *wchan)
/** /**
* WaitChannel_WakeAll -- * WaitChannel_WakeAll --
* *
* Wakes up all threads currently sleeping on the wait channel. * Wakes up all threads currently sleeping on the wait channel.
* *
* Side Effects: * Side Effects:
* Releases all thread references. * Releases all thread references.
*/ */
void void
WaitChannel_WakeAll(WaitChannel *wchan) WaitChannel_WakeAll(WaitChannel *wchan)