On Monday 13 August 2007 11:22, Ming Liu wrote: > Dear Momen, > OK. I see now. So you mean condition is only to judge whether a sleeping > process could be waken up or not when wake_up() is executed in other > processes or interrupt handlers. What really wakes the process up is still > the function of wake_up, right? We just execute wake_up() and then check if > condition is true. If yes, the process will leave its sleeping and wake up; > if not, it keep sleeping. Am I right?
Actually, the process will wake up every time you call wake_up(). It will then evaluate the condition. If the condition is true, the process will return from wait_event. If the condition is false, it will go back to sleep. Best regards, Laurent Pinchart _______________________________________________ Linuxppc-embedded mailing list Linuxppc-embedded@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-embedded