Re: flush_scheduled_tasks() question

Manfred Spraul (manfred@colorfullife.com)
Mon, 29 Jan 2001 11:15:47 +0100


David Woodhouse wrote:
>
> -static struct tq_struct dummy_task;
> +static struct tq_struct dummy_task /* = all zero */;
>
That comment is superflous - that's just C.
The non-obvious part is

+static struct tq_struct dummy_task; /* remains zero, run_task_queue()
supports tqs.routine==NULL*/

BUT: The implementation isn't thread safe: what if multiple threads call
flush_scheduled_tasks()?

--
	Manfred
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/