Re: [patch 03/13] GRU - dynamic allocation of kernel contexts

From: Andrew Morton
Date: Thu Apr 09 2009 - 18:40:41 EST


On Mon, 06 Apr 2009 11:08:12 -0500
steiner@xxxxxxx wrote:

> @@ -803,12 +803,13 @@ again:
> }
>
> if (!gts->ts_gru) {
> - if (!gru_assign_gru_context(gts)) {
> + if (!gru_assign_gru_context(gts, blade_id)) {
> mutex_unlock(&gts->ts_ctxlock);
> preempt_enable();

It's strange (but not buggy) to do the operations in this order.

preempt_enable();
mutex_unlock(...);

would be more natural.

> schedule_timeout(GRU_ASSIGN_DELAY); /* true hack ZZZ */

afacit the hack doesn't do anything because the caller is still in
state TASK_RUNNING.


> + blade_id = uv_numa_blade_id();
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/