#define __wait_event_interruptible(wq, condition, ret) \ do { \ DEFINE_WAIT(__wait); \ \
for (;;) { \ prepare_to_wait(&wq, &__wait, TASK_INTERRUPTIBLE); \
if (condition) \ break; \ if (!signal_pending(current)) { \
schedule(); \
continue; \ } \ ret = -ERESTARTSYS; \ break; \
} \ finish_wait(&wq, &__wait); \
} while (0)