• Home
  • Raw
  • Download

Lines Matching full:condition

264 #define ___wait_cond_timeout(condition)						\  argument
266 bool __cond = (condition); \
283 * to wrap the condition.
290 #define ___wait_event(wq_head, condition, state, exclusive, ret, cmd) \ argument
300 if (condition) \
314 #define __wait_event(wq_head, condition) \ argument
315 (void)___wait_event(wq_head, condition, TASK_UNINTERRUPTIBLE, 0, 0, \
319 * wait_event - sleep until a condition gets true
321 * @condition: a C expression for the event to wait for
324 * @condition evaluates to true. The @condition is checked each time
328 * change the result of the wait condition.
330 #define wait_event(wq_head, condition) \ argument
333 if (condition) \
335 __wait_event(wq_head, condition); \
338 #define __io_wait_event(wq_head, condition) \ argument
339 (void)___wait_event(wq_head, condition, TASK_UNINTERRUPTIBLE, 0, 0, \
345 #define io_wait_event(wq_head, condition) \ argument
348 if (condition) \
350 __io_wait_event(wq_head, condition); \
353 #define __wait_event_freezable(wq_head, condition) \ argument
354 ___wait_event(wq_head, condition, TASK_INTERRUPTIBLE, 0, 0, \
358 * wait_event_freezable - sleep (or freeze) until a condition gets true
360 * @condition: a C expression for the event to wait for
363 * to system load) until the @condition evaluates to true. The
364 * @condition is checked each time the waitqueue @wq_head is woken up.
367 * change the result of the wait condition.
369 #define wait_event_freezable(wq_head, condition) \ argument
373 if (!(condition)) \
374 __ret = __wait_event_freezable(wq_head, condition); \
378 #define __wait_event_timeout(wq_head, condition, timeout) \ argument
379 ___wait_event(wq_head, ___wait_cond_timeout(condition), \
384 * wait_event_timeout - sleep until a condition gets true or a timeout elapses
386 * @condition: a C expression for the event to wait for
390 * @condition evaluates to true. The @condition is checked each time
394 * change the result of the wait condition.
397 * 0 if the @condition evaluated to %false after the @timeout elapsed,
398 * 1 if the @condition evaluated to %true after the @timeout elapsed,
399 * or the remaining jiffies (at least 1) if the @condition evaluated
402 #define wait_event_timeout(wq_head, condition, timeout) \ argument
406 if (!___wait_cond_timeout(condition)) \
407 __ret = __wait_event_timeout(wq_head, condition, timeout); \
411 #define __wait_event_freezable_timeout(wq_head, condition, timeout) \ argument
412 ___wait_event(wq_head, ___wait_cond_timeout(condition), \
420 #define wait_event_freezable_timeout(wq_head, condition, timeout) \ argument
424 if (!___wait_cond_timeout(condition)) \
425 __ret = __wait_event_freezable_timeout(wq_head, condition, timeout); \
429 #define __wait_event_exclusive_cmd(wq_head, condition, cmd1, cmd2) \ argument
430 (void)___wait_event(wq_head, condition, TASK_UNINTERRUPTIBLE, 1, 0, \
435 #define wait_event_exclusive_cmd(wq_head, condition, cmd1, cmd2) \ argument
437 if (condition) \
439 __wait_event_exclusive_cmd(wq_head, condition, cmd1, cmd2); \
442 #define __wait_event_cmd(wq_head, condition, cmd1, cmd2) \ argument
443 (void)___wait_event(wq_head, condition, TASK_UNINTERRUPTIBLE, 0, 0, \
447 * wait_event_cmd - sleep until a condition gets true
449 * @condition: a C expression for the event to wait for
454 * @condition evaluates to true. The @condition is checked each time
458 * change the result of the wait condition.
460 #define wait_event_cmd(wq_head, condition, cmd1, cmd2) \ argument
462 if (condition) \
464 __wait_event_cmd(wq_head, condition, cmd1, cmd2); \
467 #define __wait_event_interruptible(wq_head, condition) \ argument
468 ___wait_event(wq_head, condition, TASK_INTERRUPTIBLE, 0, 0, \
472 * wait_event_interruptible - sleep until a condition gets true
474 * @condition: a C expression for the event to wait for
477 * @condition evaluates to true or a signal is received.
478 * The @condition is checked each time the waitqueue @wq_head is woken up.
481 * change the result of the wait condition.
484 * signal and 0 if @condition evaluated to true.
486 #define wait_event_interruptible(wq_head, condition) \ argument
490 if (!(condition)) \
491 __ret = __wait_event_interruptible(wq_head, condition); \
495 #define __wait_event_interruptible_timeout(wq_head, condition, timeout) \ argument
496 ___wait_event(wq_head, ___wait_cond_timeout(condition), \
501 * wait_event_interruptible_timeout - sleep until a condition gets true or a timeout elapses
503 * @condition: a C expression for the event to wait for
507 * @condition evaluates to true or a signal is received.
508 * The @condition is checked each time the waitqueue @wq_head is woken up.
511 * change the result of the wait condition.
514 * 0 if the @condition evaluated to %false after the @timeout elapsed,
515 * 1 if the @condition evaluated to %true after the @timeout elapsed,
516 * the remaining jiffies (at least 1) if the @condition evaluated
520 #define wait_event_interruptible_timeout(wq_head, condition, timeout) \ argument
524 if (!___wait_cond_timeout(condition)) \
526 condition, timeout); \
530 #define __wait_event_hrtimeout(wq_head, condition, timeout, state) \ argument
543 __ret = ___wait_event(wq_head, condition, state, 0, 0, \
556 * wait_event_hrtimeout - sleep until a condition gets true or a timeout elapses
558 * @condition: a C expression for the event to wait for
562 * @condition evaluates to true or a signal is received.
563 * The @condition is checked each time the waitqueue @wq_head is woken up.
566 * change the result of the wait condition.
568 * The function returns 0 if @condition became true, or -ETIME if the timeout
571 #define wait_event_hrtimeout(wq_head, condition, timeout) \ argument
575 if (!(condition)) \
576 __ret = __wait_event_hrtimeout(wq_head, condition, timeout, \
582 * wait_event_interruptible_hrtimeout - sleep until a condition gets true or a timeout elapses
584 * @condition: a C expression for the event to wait for
588 * @condition evaluates to true or a signal is received.
589 * The @condition is checked each time the waitqueue @wq is woken up.
592 * change the result of the wait condition.
594 * The function returns 0 if @condition became true, -ERESTARTSYS if it was
597 #define wait_event_interruptible_hrtimeout(wq, condition, timeout) \ argument
601 if (!(condition)) \
602 __ret = __wait_event_hrtimeout(wq, condition, timeout, \
607 #define __wait_event_interruptible_exclusive(wq, condition) \ argument
608 ___wait_event(wq, condition, TASK_INTERRUPTIBLE, 1, 0, \
611 #define wait_event_interruptible_exclusive(wq, condition) \ argument
615 if (!(condition)) \
616 __ret = __wait_event_interruptible_exclusive(wq, condition); \
620 #define __wait_event_killable_exclusive(wq, condition) \ argument
621 ___wait_event(wq, condition, TASK_KILLABLE, 1, 0, \
624 #define wait_event_killable_exclusive(wq, condition) \ argument
628 if (!(condition)) \
629 __ret = __wait_event_killable_exclusive(wq, condition); \
634 #define __wait_event_freezable_exclusive(wq, condition) \ argument
635 ___wait_event(wq, condition, TASK_INTERRUPTIBLE, 1, 0, \
638 #define wait_event_freezable_exclusive(wq, condition) \ argument
642 if (!(condition)) \
643 __ret = __wait_event_freezable_exclusive(wq, condition); \
648 * wait_event_idle - wait for a condition without contributing to system load
650 * @condition: a C expression for the event to wait for
653 * @condition evaluates to true.
654 * The @condition is checked each time the waitqueue @wq_head is woken up.
657 * change the result of the wait condition.
660 #define wait_event_idle(wq_head, condition) \ argument
663 if (!(condition)) \
664 ___wait_event(wq_head, condition, TASK_IDLE, 0, 0, schedule()); \
668 * wait_event_idle_exclusive - wait for a condition with contributing to system load
670 * @condition: a C expression for the event to wait for
673 * @condition evaluates to true.
674 * The @condition is checked each time the waitqueue @wq_head is woken up.
681 * change the result of the wait condition.
684 #define wait_event_idle_exclusive(wq_head, condition) \ argument
687 if (!(condition)) \
688 ___wait_event(wq_head, condition, TASK_IDLE, 1, 0, schedule()); \
691 #define __wait_event_idle_timeout(wq_head, condition, timeout) \ argument
692 ___wait_event(wq_head, ___wait_cond_timeout(condition), \
697 * wait_event_idle_timeout - sleep without load until a condition becomes true or a timeout elapses
699 * @condition: a C expression for the event to wait for
703 * @condition evaluates to true. The @condition is checked each time
707 * change the result of the wait condition.
710 * 0 if the @condition evaluated to %false after the @timeout elapsed,
711 * 1 if the @condition evaluated to %true after the @timeout elapsed,
712 * or the remaining jiffies (at least 1) if the @condition evaluated
715 #define wait_event_idle_timeout(wq_head, condition, timeout) \ argument
719 if (!___wait_cond_timeout(condition)) \
720 __ret = __wait_event_idle_timeout(wq_head, condition, timeout); \
724 #define __wait_event_idle_exclusive_timeout(wq_head, condition, timeout) \ argument
725 ___wait_event(wq_head, ___wait_cond_timeout(condition), \
730 …* wait_event_idle_exclusive_timeout - sleep without load until a condition becomes true or a timeo…
732 * @condition: a C expression for the event to wait for
736 * @condition evaluates to true. The @condition is checked each time
744 * change the result of the wait condition.
747 * 0 if the @condition evaluated to %false after the @timeout elapsed,
748 * 1 if the @condition evaluated to %true after the @timeout elapsed,
749 * or the remaining jiffies (at least 1) if the @condition evaluated
752 #define wait_event_idle_exclusive_timeout(wq_head, condition, timeout) \ argument
756 if (!___wait_cond_timeout(condition)) \
757 __ret = __wait_event_idle_exclusive_timeout(wq_head, condition, timeout);\
764 #define __wait_event_interruptible_locked(wq, condition, exclusive, fn) \ argument
774 } while (!(condition)); \
782 * wait_event_interruptible_locked - sleep until a condition gets true
784 * @condition: a C expression for the event to wait for
787 * @condition evaluates to true or a signal is received.
788 * The @condition is checked each time the waitqueue @wq is woken up.
791 * unlocked while sleeping but @condition testing is done while lock
799 * change the result of the wait condition.
802 * signal and 0 if @condition evaluated to true.
804 #define wait_event_interruptible_locked(wq, condition) \ argument
805 ((condition) \
806 ? 0 : __wait_event_interruptible_locked(wq, condition, 0, do_wait_intr))
809 * wait_event_interruptible_locked_irq - sleep until a condition gets true
811 * @condition: a C expression for the event to wait for
814 * @condition evaluates to true or a signal is received.
815 * The @condition is checked each time the waitqueue @wq is woken up.
818 * unlocked while sleeping but @condition testing is done while lock
826 * change the result of the wait condition.
829 * signal and 0 if @condition evaluated to true.
831 #define wait_event_interruptible_locked_irq(wq, condition) \ argument
832 ((condition) \
833 ? 0 : __wait_event_interruptible_locked(wq, condition, 0, do_wait_intr_irq))
836 * wait_event_interruptible_exclusive_locked - sleep exclusively until a condition gets true
838 * @condition: a C expression for the event to wait for
841 * @condition evaluates to true or a signal is received.
842 * The @condition is checked each time the waitqueue @wq is woken up.
845 * unlocked while sleeping but @condition testing is done while lock
857 * change the result of the wait condition.
860 * signal and 0 if @condition evaluated to true.
862 #define wait_event_interruptible_exclusive_locked(wq, condition) \ argument
863 ((condition) \
864 ? 0 : __wait_event_interruptible_locked(wq, condition, 1, do_wait_intr))
867 * wait_event_interruptible_exclusive_locked_irq - sleep until a condition gets true
869 * @condition: a C expression for the event to wait for
872 * @condition evaluates to true or a signal is received.
873 * The @condition is checked each time the waitqueue @wq is woken up.
876 * unlocked while sleeping but @condition testing is done while lock
888 * change the result of the wait condition.
891 * signal and 0 if @condition evaluated to true.
893 #define wait_event_interruptible_exclusive_locked_irq(wq, condition) \ argument
894 ((condition) \
895 ? 0 : __wait_event_interruptible_locked(wq, condition, 1, do_wait_intr_irq))
898 #define __wait_event_killable(wq, condition) \ argument
899 ___wait_event(wq, condition, TASK_KILLABLE, 0, 0, schedule())
902 * wait_event_killable - sleep until a condition gets true
904 * @condition: a C expression for the event to wait for
907 * @condition evaluates to true or a signal is received.
908 * The @condition is checked each time the waitqueue @wq_head is woken up.
911 * change the result of the wait condition.
914 * signal and 0 if @condition evaluated to true.
916 #define wait_event_killable(wq_head, condition) \ argument
920 if (!(condition)) \
921 __ret = __wait_event_killable(wq_head, condition); \
925 #define __wait_event_killable_timeout(wq_head, condition, timeout) \ argument
926 ___wait_event(wq_head, ___wait_cond_timeout(condition), \
931 * wait_event_killable_timeout - sleep until a condition gets true or a timeout elapses
933 * @condition: a C expression for the event to wait for
937 * @condition evaluates to true or a kill signal is received.
938 * The @condition is checked each time the waitqueue @wq_head is woken up.
941 * change the result of the wait condition.
944 * 0 if the @condition evaluated to %false after the @timeout elapsed,
945 * 1 if the @condition evaluated to %true after the @timeout elapsed,
946 * the remaining jiffies (at least 1) if the @condition evaluated
952 #define wait_event_killable_timeout(wq_head, condition, timeout) \ argument
956 if (!___wait_cond_timeout(condition)) \
958 condition, timeout); \
963 #define __wait_event_lock_irq(wq_head, condition, lock, cmd) \ argument
964 (void)___wait_event(wq_head, condition, TASK_UNINTERRUPTIBLE, 0, 0, \
971 * wait_event_lock_irq_cmd - sleep until a condition gets true. The
972 * condition is checked under the lock. This
976 * @condition: a C expression for the event to wait for
983 * @condition evaluates to true. The @condition is checked each time
987 * change the result of the wait condition.
993 #define wait_event_lock_irq_cmd(wq_head, condition, lock, cmd) \ argument
995 if (condition) \
997 __wait_event_lock_irq(wq_head, condition, lock, cmd); \
1001 * wait_event_lock_irq - sleep until a condition gets true. The
1002 * condition is checked under the lock. This
1006 * @condition: a C expression for the event to wait for
1011 * @condition evaluates to true. The @condition is checked each time
1015 * change the result of the wait condition.
1020 #define wait_event_lock_irq(wq_head, condition, lock) \ argument
1022 if (condition) \
1024 __wait_event_lock_irq(wq_head, condition, lock, ); \
1028 #define __wait_event_interruptible_lock_irq(wq_head, condition, lock, cmd) \ argument
1029 ___wait_event(wq_head, condition, TASK_INTERRUPTIBLE, 0, 0, \
1036 * wait_event_interruptible_lock_irq_cmd - sleep until a condition gets true.
1037 * The condition is checked under the lock. This is expected to
1040 * @condition: a C expression for the event to wait for
1047 * @condition evaluates to true or a signal is received. The @condition is
1051 * change the result of the wait condition.
1058 * and 0 if @condition evaluated to true.
1060 #define wait_event_interruptible_lock_irq_cmd(wq_head, condition, lock, cmd) \ argument
1063 if (!(condition)) \
1065 condition, lock, cmd); \
1070 * wait_event_interruptible_lock_irq - sleep until a condition gets true.
1071 * The condition is checked under the lock. This is expected
1074 * @condition: a C expression for the event to wait for
1079 * @condition evaluates to true or signal is received. The @condition is
1083 * change the result of the wait condition.
1089 * and 0 if @condition evaluated to true.
1091 #define wait_event_interruptible_lock_irq(wq_head, condition, lock) \ argument
1094 if (!(condition)) \
1096 condition, lock,); \
1100 #define __wait_event_lock_irq_timeout(wq_head, condition, lock, timeout, state) \ argument
1101 ___wait_event(wq_head, ___wait_cond_timeout(condition), \
1108 * wait_event_interruptible_lock_irq_timeout - sleep until a condition gets
1109 * true or a timeout elapses. The condition is checked under
1112 * @condition: a C expression for the event to wait for
1118 * @condition evaluates to true or signal is received. The @condition is
1122 * change the result of the wait condition.
1129 * if the condition evaluated to true before the timeout elapsed.
1131 #define wait_event_interruptible_lock_irq_timeout(wq_head, condition, lock, \ argument
1135 if (!___wait_cond_timeout(condition)) \
1137 wq_head, condition, lock, timeout, \
1142 #define wait_event_lock_irq_timeout(wq_head, condition, lock, timeout) \ argument
1145 if (!___wait_cond_timeout(condition)) \
1147 wq_head, condition, lock, timeout, \