Messages in this thread | | | Date | Thu, 19 Feb 2004 00:10:11 -0800 | From | Andrew Morton <> | Subject | Re: keventd_create_kthread |
| |
Ingo Molnar <mingo@redhat.com> wrote: > > i'd strongly advise against using wait_task_inactive() in > keventd_create_kthread() - it's _polling_. We must not do any polling like > that in any modern interface. Why does keventd_create_kthread() need > wait_task_inactive()?
The way it's designed, we _have_ to wait until the new kthread has gone to sleep, because we poke him again with wake_up_process().
However, if that wake_up_process() comes too early we'll just flip the new thread out of TASK_INTERUPTIBLE into TASK_RUNNING and the schedule() in kthread() will fall straight through. So perhaps we can simply remove the wait_task_inactive()?
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |